features: notifications fix + tests fix + menu/router fixes

This commit is contained in:
Jean-Baptiste Pasquier 2021-01-22 14:21:25 +01:00
parent bc64019b63
commit b541d9e6d7
36 changed files with 561 additions and 529 deletions

View File

@ -16,9 +16,9 @@ context('Create Channel Browser Testing', () => {
description = 'Test Description ',
subtitle = 'Test Subtitle ';
it('should visit the channel creation screen', () => {
cy.visit('/admin/admin-circle-create');
cy.visit('/admin-circles-create');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-circle-create');
expect(loc.pathname).to.eq('/admin-circles-create');
});
});
it('should enter correct channel data', () => {
@ -26,20 +26,20 @@ context('Create Channel Browser Testing', () => {
channelName += num;
description += num;
subtitle += num;
cy.get('#admin-circle-create input[name="name"]').clear().type(channelName);
cy.get('#admin-circle-create input[name="name"]').should('have.value', channelName);
cy.get('#admin-circle-create input[name="subtitle"]').clear().type(subtitle);
cy.get('#admin-circle-create input[name="subtitle"]').should('have.value', subtitle);
cy.get('#admin-circle-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-circle-create [name="description"] [contenteditable="true"]').should('have.value', description);
cy.get('#admin-circles-create input[name="name"]').clear().type(channelName);
cy.get('#admin-circles-create input[name="name"]').should('have.value', channelName);
cy.get('#admin-circles-create input[name="subtitle"]').clear().type(subtitle);
cy.get('#admin-circles-create input[name="subtitle"]').should('have.value', subtitle);
cy.get('#admin-circles-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-circles-create [name="description"] [contenteditable="true"]').should('have.value', description);
});
});
it('should click on create channel button', () => {
cy.get('#admin-circle-create input[type="submit"]').click();
cy.get('#admin-circles-create input[type="submit"]').click();
});
it('should land on channels list screen', () => {
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
expect(loc.pathname).to.eq('/admin-circles');
});
});
it('should land newly created channel on channels list screen', () => {
@ -54,9 +54,9 @@ context('Create Channel Browser Testing', () => {
description = 'Test Description ',
subtitle = 'Test Subtitle ';
it('should visit the channel creation screen', () => {
cy.visit('/admin/admin-circle-create');
cy.visit('/admin-circles-create');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-circle-create');
expect(loc.pathname).to.eq('/admin-circles-create');
});
});
it('should enter correct channel data', () => {
@ -64,20 +64,20 @@ context('Create Channel Browser Testing', () => {
channelName += num;
description += num;
subtitle += num;
cy.get('#admin-circle-create input[name="name"]').clear().type(channelName);
cy.get('#admin-circle-create input[name="name"]').should('have.value', channelName);
cy.get('#admin-circle-create input[name="subtitle"]').clear().type(subtitle);
cy.get('#admin-circle-create input[name="subtitle"]').should('have.value', subtitle);
cy.get('#admin-circle-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-circle-create [name="description"] [contenteditable="true"]').should('have.value', description);
cy.get('#admin-circles-create input[name="name"]').clear().type(channelName);
cy.get('#admin-circles-create input[name="name"]').should('have.value', channelName);
cy.get('#admin-circles-create input[name="subtitle"]').clear().type(subtitle);
cy.get('#admin-circles-create input[name="subtitle"]').should('have.value', subtitle);
cy.get('#admin-circles-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-circles-create [name="description"] [contenteditable="true"]').should('have.value', description);
});
});
it('should click on create channel button', () => {
cy.get('#admin-circle-create input[type="submit"]').click();
cy.get('#admin-circles-create input[type="submit"]').click();
});
it('should land on channels list screen', () => {
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
expect(loc.pathname).to.eq('/admin-circles');
});
});
it('should land newly created channel on channels list screen', () => {
@ -92,9 +92,9 @@ context('Create Channel Browser Testing', () => {
description = 'Test Description ',
subtitle = 'Test Subtitle ';
it('should visit the channel creation screen', () => {
cy.visit('/admin/admin-circle-create');
cy.visit('/admin-circles-create');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-circle-create');
expect(loc.pathname).to.eq('/admin-circles-create');
});
});
it('should enter correct channel data', () => {
@ -102,20 +102,20 @@ context('Create Channel Browser Testing', () => {
channelName += num;
description += num;
subtitle += num;
cy.get('#admin-circle-create input[name="name"]').clear().type(channelName);
cy.get('#admin-circle-create input[name="name"]').should('have.value', channelName);
cy.get('#admin-circle-create input[name="subtitle"]').clear().type(subtitle);
cy.get('#admin-circle-create input[name="subtitle"]').should('have.value', subtitle);
cy.get('#admin-circle-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-circle-create [name="description"] [contenteditable="true"]').should('have.value', description);
cy.get('#admin-circles-create input[name="name"]').clear().type(channelName);
cy.get('#admin-circles-create input[name="name"]').should('have.value', channelName);
cy.get('#admin-circles-create input[name="subtitle"]').clear().type(subtitle);
cy.get('#admin-circles-create input[name="subtitle"]').should('have.value', subtitle);
cy.get('#admin-circles-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-circles-create [name="description"] [contenteditable="true"]').should('have.value', description);
});
});
it('should click on create channel button', () => {
cy.get('#admin-circle-create input[type="submit"]').click();
cy.get('#admin-circles-create input[type="submit"]').click();
});
it('should land on channels list screen', () => {
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
expect(loc.pathname).to.eq('/admin-circles');
});
});
it('should land newly created channel on channels list screen', () => {

View File

@ -16,9 +16,9 @@ context('Create Project Browser Testing', () => {
customerName = 'Test Customer ',
description = 'Test Description ';
it('should visit the project creation screen', () => {
cy.visit('/admin/admin-projects/admin-project-create');
cy.visit('/admin-projects-create');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-projects/admin-project-create');
expect(loc.pathname).to.eq('/admin-projects-create');
});
});
it('should enter correct project data', () => {
@ -26,20 +26,20 @@ context('Create Project Browser Testing', () => {
projectName += num;
customerName += num;
description += num;
cy.get('#admin-project-create input[name="customer.name"]').clear().type(customerName);
cy.get('#admin-project-create input[name="customer.name"]').should('have.value', customerName);
cy.get('#admin-project-create input[name="name"]').clear().type(projectName);
cy.get('#admin-project-create input[name="name"]').should('have.value', projectName);
cy.get('#admin-project-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-project-create [name="description"] [contenteditable="true"]').should('have.value', description);
cy.get('#admin-projects-create input[name="customer.name"]').clear().type(customerName);
cy.get('#admin-projects-create input[name="customer.name"]').should('have.value', customerName);
cy.get('#admin-projects-create input[name="name"]').clear().type(projectName);
cy.get('#admin-projects-create input[name="name"]').should('have.value', projectName);
cy.get('#admin-projects-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-projects-create [name="description"] [contenteditable="true"]').should('have.value', description);
});
});
it('should click on create project button', () => {
cy.get('#admin-project-create input[type="submit"]').click();
cy.get('#admin-projects-create input[type="submit"]').click();
});
it('should land on projects list screen', () => {
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-projects');
expect(loc.pathname).to.eq('/admin-projects');
});
});
it('should land newly created project on projects list screen', () => {
@ -54,9 +54,9 @@ context('Create Project Browser Testing', () => {
customerName = 'Test Customer ',
description = 'Test Description ';
it('should visit the project creation screen', () => {
cy.visit('/admin/admin-projects/admin-project-create');
cy.visit('/admin-projects-create');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-projects/admin-project-create');
expect(loc.pathname).to.eq('/admin-projects-create');
});
});
it('should enter correct project data', () => {
@ -64,20 +64,20 @@ context('Create Project Browser Testing', () => {
projectName += num;
customerName += num;
description += num;
cy.get('#admin-project-create input[name="customer.name"]').clear().type(customerName);
cy.get('#admin-project-create input[name="customer.name"]').should('have.value', customerName);
cy.get('#admin-project-create input[name="name"]').clear().type(projectName);
cy.get('#admin-project-create input[name="name"]').should('have.value', projectName);
cy.get('#admin-project-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-project-create [name="description"] [contenteditable="true"]').should('have.value', description);
cy.get('#admin-projects-create input[name="customer.name"]').clear().type(customerName);
cy.get('#admin-projects-create input[name="customer.name"]').should('have.value', customerName);
cy.get('#admin-projects-create input[name="name"]').clear().type(projectName);
cy.get('#admin-projects-create input[name="name"]').should('have.value', projectName);
cy.get('#admin-projects-create [name="description"] [contenteditable="true"]').clear().type(description);
cy.get('#admin-projects-create [name="description"] [contenteditable="true"]').should('have.value', description);
});
});
it('should click on create project button', () => {
cy.get('#admin-project-create input[type="submit"]').click();
cy.get('#admin-projects-create input[type="submit"]').click();
});
it('should land on projects list screen', () => {
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-projects');
expect(loc.pathname).to.eq('/admin-projects');
});
});
it('should land newly created project on projects list screen', () => {

View File

@ -25,9 +25,9 @@
// it('should login', () => cy.login());
// describe('User Creation process', () => {
// it('should visit the user creation screen', () => {
// cy.visit('/admin/admin-users/admin-users-create');
// cy.visit('/admin-users-create');
// cy.location().should((loc) => {
// expect(loc.pathname).to.eq('/admin/admin-users/admin-users-create');
// expect(loc.pathname).to.eq('/admin-users-create');
// });
// });
// it('should enter correct user data', () => {
@ -45,7 +45,7 @@
// });
// it('should land on users list screen', () => {
// cy.location().should((loc) => {
// expect(loc.pathname).to.eq('/admin/admin-users');
// expect(loc.pathname).to.eq('/admin-users');
// });
// });
// it('should land newly created user on users list screen', () => {

View File

@ -24,9 +24,9 @@ context('Delete Channel Browser Testing', () => {
describe('Channel Retirement process', () => {
let channelsLength;
it('should visit the channels list screen', () => {
cy.visit('/admin');
cy.visit('/admin-circles');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
expect(loc.pathname).to.eq('/admin-circles');
});
});
it('should visit the last channel edit screen', () => {

View File

@ -24,9 +24,9 @@ context('Edit Channel Browser Testing', () => {
it('should login', () => cy.login());
describe('Channel Edition process', () => {
it('should visit the channel list screen', () => {
cy.visit('/admin');
cy.visit('/admin-circles');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
expect(loc.pathname).to.eq('/admin-circles');
});
});
it('should visit the last channel edit screen', () => {

View File

@ -26,9 +26,9 @@ context('Edit Project Browser Testing', () => {
it('should login', () => cy.login());
describe('Project Edition process', () => {
it('should visit the project list screen', () => {
cy.visit('/admin/admin-projects');
cy.visit('/admin-projects');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-projects');
expect(loc.pathname).to.eq('/admin-projects');
});
});
it('should visit the last project edit screen', () => {

View File

@ -24,9 +24,9 @@ context('Leave Channel Browser Testing', () => {
it('should login', () => cy.login());
describe('Channel Leaving process', () => {
it('should visit the channels list screen', () => {
cy.visit('/admin');
cy.visit('/admin-circles');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
expect(loc.pathname).to.eq('/admin-circles');
});
});
it('should click the last channel leave button', () => {

View File

@ -24,9 +24,9 @@ context('Leave Project Browser Testing', () => {
it('should login', () => cy.login());
describe('Project Leaving process', () => {
it('should visit the projects list screen', () => {
cy.visit('/admin/admin-projects');
cy.visit('/admin-projects');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-projects');
expect(loc.pathname).to.eq('/admin-projects');
});
});
it('should click the last project leave button', () => {

View File

@ -24,9 +24,9 @@ context('Retire Channel Browser Testing', () => {
describe('Channel Retirement process', () => {
let channelsLength;
it('should visit the channels list screen', () => {
cy.visit('/admin');
cy.visit('/admin-circles');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
expect(loc.pathname).to.eq('/admin-circles');
});
});
it('should visit the last channel edit screen', () => {

View File

@ -24,9 +24,9 @@ context('Retire Project Browser Testing', () => {
describe('Project Retirement process', () => {
let projectsLength;
it('should visit the projects list screen', () => {
cy.visit('/admin/admin-projects');
cy.visit('/admin-projects');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin/admin-projects');
expect(loc.pathname).to.eq('/admin-projects');
});
});
it('should visit the last project edit screen', () => {

View File

@ -58,12 +58,12 @@ context('Browser testing', () => {
// it('should navigate the Administration from left menu', () => {
// cy.get('.create > solid-link').click();
// cy.get('#admin-circles > .content-box > .content-box__header > .without-margin').contains('Administration');
// cy.get('#admin-circle-list > .content-box__info > .admin-header > .admin-header__title').contains('Circles');
// cy.get('#admin-circles > .content-box__info > .admin-header > .admin-header__title').contains('Circles');
// });
// it('should navigate to Circle creation', () => {
// cy.get('#admin-circle-list > .content-box__info > .admin-header > .button').click();
// cy.get('#admin-circles > .content-box__info > .admin-header > .button').click();
// cy.location().should((loc) => {
// expect(loc.pathname).to.contain('admin-circle-create');
// expect(loc.pathname).to.contain('admin-circles-create');
// });
// });
// var name = new Uint32Array(1);
@ -72,8 +72,8 @@ context('Browser testing', () => {
// it('should allow Circle Creation', () => {
// cy.get('form > solid-form-label-text[name="name"] > label > input').type(name);
// cy.get('.content-box__info > solid-form > form > solid-form-label-text[name="description"] > label > input').type('With a great description!');
// cy.get('#admin-circle-create > .content-box__info > solid-form > form > [type="submit"]').click();
// cy.get('#admin-circle-list > div > div.table > solid-display').contains(name);
// cy.get('#admin-circles-create > .content-box__info > solid-form > form > [type="submit"]').click();
// cy.get('#admin-circles > div > div.table > solid-display').contains(name);
// });
// it('should open the circle information page', () => {
// cy.screenshot();

17
package-lock.json generated
View File

@ -2271,11 +2271,18 @@
"sha.js": "^2.4.8"
}
},
"cross-env": {
"version": "7.0.3",
"resolved": "https://registry.npmjs.org/cross-env/-/cross-env-7.0.3.tgz",
"integrity": "sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==",
"requires": {
"cross-spawn": "^7.0.1"
}
},
"cross-spawn": {
"version": "7.0.3",
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",
"integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==",
"dev": true,
"requires": {
"path-key": "^3.1.0",
"shebang-command": "^2.0.0",
@ -2286,7 +2293,6 @@
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
"integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
"dev": true,
"requires": {
"shebang-regex": "^3.0.0"
}
@ -2294,14 +2300,12 @@
"shebang-regex": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
"integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==",
"dev": true
"integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A=="
},
"which": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
"integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
"dev": true,
"requires": {
"isexe": "^2.0.0"
}
@ -5273,8 +5277,7 @@
"path-key": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
"integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==",
"dev": true
"integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q=="
},
"path-parse": {
"version": "1.0.6",

View File

@ -8,7 +8,7 @@
},
"scripts": {
"prebuild": "rimraf build",
"build": "NODE_ENV='production' node internal/parcel.js",
"build": "cross-env NODE_ENV='production' node internal/parcel.js",
"watch": "rimraf build .cache && node internal/parcel.js",
"cypress:open": "cypress open",
"cypress:verify": "cypress verify",
@ -46,6 +46,7 @@
},
"dependencies": {
"@startinblox/hubl-styling-framework": "^1.4.4",
"cross-env": "^7.0.3",
"fs-extra": "^9.0.1",
"normalize.css": "^8.0.1",
"parcel-bundler": "^1.12.4",

View File

@ -24,16 +24,16 @@ if endpoints.get
//- script(type="module" src="/lib/sib-resource/sib-resource.js" defer)
if endpoints.get.joboffers
//- script(type="module" src="https://cdn.skypack.dev/@startinblox/component-job-board@1.3" defer)
script(type="module" src="/lib/solid-job-board/dist/index.js" defer)
script(type="module" src="https://cdn.skypack.dev/@startinblox/component-job-board@beta" defer)
//- script(type="module" src="/lib/solid-job-board/dist/index.js" defer)
if endpoints.get.uploads && endpoints.get.skills && endpoints.get.users
//- script(type="module" src="https://cdn.skypack.dev/@startinblox/component-directory@1.4" defer)
script(type="module" src="/lib/solid-directory/dist/index.js" defer)
script(type="module" src="https://cdn.skypack.dev/@startinblox/component-directory@beta" defer)
//- script(type="module" src="/lib/solid-directory/dist/index.js" defer)
if endpoints.get.dashboards
//- script(type="module" src="https://cdn.skypack.dev/@startinblox/component-dashboard@0.7" defer)
script(type="module" src="/lib/solid-dashboard/dist/index.js" defer)
script(type="module" src="https://cdn.skypack.dev/@startinblox/component-dashboard@beta" defer)
//- script(type="module" src="/lib/solid-dashboard/dist/index.js" defer)
if endpoints.get.users
script(type="module" src="https://cdn.skypack.dev/@startinblox/component-chat@1.7" defer)

View File

@ -38,10 +38,10 @@ html(lang="en")
script(src="index.js" defer)
body
body.notLoggedIn(style='visibility:hidden;')
if endpoints.get && endpoints.post
//- include views/partials/notifications.pug
include views/partials/notifications.pug
include views/partials/widgets.pug
header#header.segment.sm-full.lg-full.padding-left-large.padding-right-large.sm-padding-right-xsmall.sm-padding-left-small.shadow-small.text-disable-selection
@ -50,7 +50,7 @@ html(lang="en")
nav#main__menu.scrollbar-nav.segment.bg-color-heading.text-top.lg-quarter.jsLeftMenu
include views/partials/menu-left.pug
main#content.segment.lg-three-quarter.sm-full.text-top.notLoggedIn
main#content.segment.lg-three-quarter.sm-full.text-top
if endpoints.get.dashboards
#dashboard(hidden, data-view="dashboard").scrollbar-content
@ -101,7 +101,7 @@ html(lang="en")
#resources(hidden, data-view="resources")
include views/page-resources.pug
#admin(hidden, data-view="admin", no-render).with-sidebar.whitespace-normal
#admin
include views/page-admin.pug
#about(hidden, data-view="about", no-render)

View File

@ -1,60 +1,60 @@
document.addEventListener("DOMContentLoaded", () => {
const resizeChat = () => {
let isMobile = window.innerWidth < 993;
let isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
let isFirefoxMobile = navigator.platform.toLowerCase().indexOf("mobile") > -1 || navigator.platform.toLowerCase().indexOf("tablet") > -1;
let chatBox = Array.from(document.querySelectorAll("solid-xmpp-chat"))
.map((el) => el.shadowRoot ? el.shadowRoot.getElementById("conversejs") : false)
.filter((el) => el)
.pop();
if (chatBox) {
let chatTextArea = chatBox.querySelector(".message-form-container");
let ischatTextArea = setInterval(() => {
chatTextArea = chatBox.querySelector(".message-form-container");
if (chatTextArea) {
clearInterval(ischatTextArea);
if (
chatBox.getBoundingClientRect().height -
chatTextArea.getBoundingClientRect().height !=
chatTextArea.offsetTop
) {
let viewportChat = Array.from(
document.querySelectorAll("#viewport .chat-view")
);
viewportChat.forEach(
(c) => (c.style.height = isMobile ? (isFirefox && isFirefoxMobile) ? "calc(100vh - 106px - 57px)" : "calc(100vh - 106px)" : "calc(100vh - 64px - 83px)")
);
}
}
}, 15);
}
};
resizeChat();
// document.addEventListener("DOMContentLoaded", () => {
// const resizeChat = () => {
// let isMobile = window.innerWidth < 993;
// let isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
// let isFirefoxMobile = navigator.platform.toLowerCase().indexOf("mobile") > -1 || navigator.platform.toLowerCase().indexOf("tablet") > -1;
// let chatBox = Array.from(document.querySelectorAll("solid-xmpp-chat"))
// .map((el) => el.shadowRoot ? el.shadowRoot.getElementById("conversejs") : false)
// .filter((el) => el)
// .pop();
// if (chatBox) {
// let chatTextArea = chatBox.querySelector(".message-form-container");
// let ischatTextArea = setInterval(() => {
// chatTextArea = chatBox.querySelector(".message-form-container");
// if (chatTextArea) {
// clearInterval(ischatTextArea);
// if (
// chatBox.getBoundingClientRect().height -
// chatTextArea.getBoundingClientRect().height !=
// chatTextArea.offsetTop
// ) {
// let viewportChat = Array.from(
// document.querySelectorAll("#viewport .chat-view")
// );
// viewportChat.forEach(
// (c) => (c.style.height = isMobile ? (isFirefox && isFirefoxMobile) ? "calc(100vh - 106px - 57px)" : "calc(100vh - 106px)" : "calc(100vh - 64px - 83px)")
// );
// }
// }
// }, 15);
// }
// };
// resizeChat();
let isbody = setInterval(() => {
if (document.body) {
clearInterval(isbody);
resizeChat();
}
}, 50);
// let isbody = setInterval(() => {
// if (document.body) {
// clearInterval(isbody);
// resizeChat();
// }
// }, 50);
window.addEventListener("load", () => {
setTimeout(() => {
resizeChat();
}, 0);
});
// window.addEventListener("load", () => {
// setTimeout(() => {
// resizeChat();
// }, 0);
// });
let windowResizing;
window.addEventListener("resize", () => {
windowResizing = setTimeout(() => {
clearInterval(windowResizing);
resizeChat();
}, 50);
});
// let windowResizing;
// window.addEventListener("resize", () => {
// windowResizing = setTimeout(() => {
// clearInterval(windowResizing);
// resizeChat();
// }, 50);
// });
document.addEventListener("navigate", () => {
setTimeout(() => {
resizeChat();
}, 0);
});
});
// document.addEventListener("navigate", () => {
// setTimeout(() => {
// resizeChat();
// }, 0);
// });
// });

View File

@ -1,10 +0,0 @@
document.addEventListener("keydown", function (e) {
/*
CTRL + K : Focus on the user search
Keycode 75
*/
if(e.ctrlKey && e.which == 75) {
document.querySelector('hubl-search-users > input').focus();
e.preventDefault();
}
});

View File

@ -7,9 +7,6 @@ document.addEventListener("DOMContentLoaded", function () {
document
.querySelectorAll(".notLoggedIn")
.forEach(el => (el.style.visibility = "visible"));
document
.querySelector('.loggedIn')
.setAttribute("style", "display:none !important");
}
});
});

View File

@ -1,11 +0,0 @@
document.addEventListener("DOMContentLoaded", () => {
const menuWrappers = Array.from(document.querySelectorAll(".menu-wrapper"));
//- Toggle sub-menus
menuWrappers.forEach(menuWrapper => {
const menu = menuWrapper.querySelector(".menu");
menu.addEventListener("click", e => {
menuWrapper.classList.toggle("is-closed");
});
});
});

View File

@ -1,7 +1,7 @@
// auxiliary function closes the user profile menu
function closeUserControls() {
let userControls = document.querySelector("#user-controls");
if (userControls) userControls.removeAttribute("open");
let userControls = Array.from(document.querySelectorAll(".user-controls"));
userControls.forEach(e => e.removeAttribute("open"));
}
function closeLeftMenu() {
@ -30,13 +30,39 @@ function closeUserControls() {
document.addEventListener("DOMContentLoaded", function() {
//- View change event
window.addEventListener("navigate", () => {
window.addEventListener("navigate", e => {
if(e.detail.route.startsWith('admin-')) {
document.querySelector('.only-on-admin').removeAttribute('hidden');
} else {
document.querySelector('.only-on-admin').setAttribute('hidden','');
}
if(e.detail.route.startsWith("admin-communities")) {
document.querySelector('solid-route[name="admin-communities"]').setAttribute('active','');
document.querySelector('.jsRightMenu solid-link[next="admin-communities"]').setAttribute('active','');
} else {
document.querySelector('solid-route[name="admin-communities"]').removeAttribute('active');
document.querySelector('.jsRightMenu solid-link[next="admin-communities"]').removeAttribute('active');
}
if(e.detail.route.startsWith("admin-circles")) {
document.querySelector('solid-route[name="admin-circles"]').setAttribute('active','');
document.querySelector('.jsRightMenu solid-link[next="admin-circles"]').setAttribute('active','');
} else {
document.querySelector('solid-route[name="admin-circles"]').removeAttribute('active');
document.querySelector('.jsRightMenu solid-link[next="admin-circles"]').removeAttribute('active');
}
if(e.detail.route.startsWith("admin-projects")) {
document.querySelector('solid-route[name="admin-projects"]').setAttribute('active','');
document.querySelector('.jsRightMenu solid-link[next="admin-projects"]').setAttribute('active','');
} else {
document.querySelector('solid-route[name="admin-projects"]').removeAttribute('active');
document.querySelector('.jsRightMenu solid-link[next="admin-projects"]').removeAttribute('active');
}
closeLeftMenu();
closeUserControls();
});
// Document -> close menu
document.addEventListener("click", event => {
if (!event.target.closest("#user-controls")) {
if (!event.target.closest(".user-controls")) {
closeUserControls();
}
if (

View File

@ -71,6 +71,10 @@ main {
/* Styles use with JS to open/close the sidebar */
&.jsRightMenu {
display: block;
solid-link[active] {
color: white;
background: var(--color-heading);
}
}
&.jsRightMenu:not([open]) {

View File

@ -46,10 +46,11 @@ header {
}
.solid-notifications__button {
margin-top: -9px;
font-size: 24px;
&::before {
margin-left: 0;
margin-left: -9px;
}
&:hover {
@ -61,7 +62,7 @@ header {
}
.solid-notifications__counter {
left: 21px;
left: 12px;
position: absolute;
top: 1px;
@ -170,7 +171,7 @@ header {
.solid-notification__avatar {
align-items: center;
background: var(--color-grey);
background: #f6f6f6;
display: flex;
height: 35px;
justify-content: center;
@ -182,7 +183,7 @@ header {
width: 35px;
img {
background-color: var(--color-grey);
background-color: #f6f6f6;
height: 100%;
object-fit: cover;
object-position: center center;
@ -400,4 +401,22 @@ header {
}
}
}
.solid-notifications__item:hover * {
color: var(--color-secondary)!important;
}
.solid-notification__content {
max-width: calc(100% - 65px);
}
.solid-notification__summary {
text-overflow: ellipsis;
display: block;
width: 100%;
}
.solid-notification__title {
overflow: hidden;
white-space: break-spaces;
text-overflow: ellipsis;
display: block;
width: 100%;
}
}

View File

@ -30,8 +30,6 @@ solid-display>div {
}
}
$small: "max-width: 768px";
.segment {
@ -106,8 +104,6 @@ $small: "max-width: 768px";
}
}
@import 'header/_index';
@import 'left-nav/_index';
@import 'content/_index';
@ -116,3 +112,10 @@ $small: "max-width: 768px";
@import 'profile/_index';
@import 'job-offers/_index';
@import 'chat/_index';
nav#main__menu {
width: 250px;
}
main#content {
width: calc(100% - 250px);
}

View File

@ -1,31 +1,42 @@
.scrollbar-content.views-container.sidebar-is-closed
.with-sidebar.whitespace-normal.only-on-admin(hidden)
.scrollbar-content.views-container.sidebar-is-closed
if endpoints.circles || (endpoints.get && endpoints.get.circles)
#admin-circles(hidden, data-view="admin-circles")
#admin-circles(hidden, data-view="admin-circles", no-render)
include partials/admin/page-admin-circles.pug
#circle-left(hidden, data-view="circle-left", no-render)
include partials/circle/page-circle-left.pug
#admin-circles-create(hidden, data-view="admin-circles-create", no-render)
include partials/admin/page-admin-circles-create.pug
if endpoints.projects || (endpoints.get && endpoints.get.projects)
#admin-projects(hidden, data-view="admin-projects")
#admin-projects(hidden, data-view="admin-projects", no-render)
include partials/admin/page-admin-projects.pug
#admin-projects-create(hidden, data-view="admin-projects-create", no-render)
include partials/admin/page-admin-projects-create.pug
#project-left(hidden, data-view="project-left", no-render)
include partials/project/page-project-left.pug
if (endpoints.users || (endpoints.get && endpoints.get.users))
#admin-communities(hidden, data-view="admin-communities")
include partials/admin/page-admin-communities.pug
nav.jsRightMenu.sidebar.whitespace-normal(role='navigation')
solid-router.segment.whitespace-normal.text-color-heading.text-bold(default-route='admin-circles')
#admin-users-create(hidden, data-view="admin-users-create", no-render)
include partials/admin/page-admin-users-create.pug
nav.jsRightMenu.sidebar.whitespace-normal(role='navigation')
.segment.whitespace-normal.text-color-heading.text-bold
ul
li.segment.lg-full.sm-full.padding-small.text-right.text-normal.jsOffsiteToggle
span.icon.icon-arrow-right.xxsmall.margin-right-xxsmall
a(data-trans='admin.menuRight.fold')
if (endpoints.users || (endpoints.get && endpoints.get.users))
solid-route.segment.lg-full.sm-full(name='admin-communities')
solid-link.segment.lg-full.sm-full(next='admin-communities')
li.segment.lg-full.sm-full.padding-medium
span.icon.ci-networking.icon-xlarge.margin-right-medium
a(data-trans='admin.menuRight.community')
if endpoints.circles || (endpoints.get && endpoints.get.circles)
solid-route.segment.lg-full.sm-full(name='admin-circles')
solid-link.segment.lg-full.sm-full(next='admin-circles')
li.segment.lg-full.sm-full.padding-medium
span.icon.ci-bubble-add.icon-xlarge.margin-right-medium
a(data-trans='admin.menuRight.circles')
if endpoints.projects || (endpoints.get && endpoints.get.projects)
solid-route.segment.lg-full.sm-full(name='admin-projects')
solid-link.segment.lg-full.sm-full(next='admin-projects')
li.segment.lg-full.sm-full.padding-medium
span.icon.ci-add.icon-xlarge.margin-right-medium
a(data-trans='admin.menuRight.projects')

View File

@ -2,7 +2,7 @@ div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-
div.segment.lg-half
h2.margin-none.text-uppercase.text-xlarge.text-letter-spacing-large(data-trans='circle.create.title')
div.segment.lg-half.sm-hidden.text-right
solid-link(class="backlink", bind-resources, next='admin-circle-list' data-trans='circle.create.backlink')
solid-link(class="backlink", bind-resources, next='admin-circles' data-trans='circle.create.backlink')
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-medium.whitespace-normal
div#loader-circles-create.loader.loader-top

View File

@ -1,14 +1,4 @@
solid-router(default-route='admin-circle-list', hidden)
solid-route(name='admin-circle-list')
solid-route(name='admin-circle-create')
solid-route(name='circle-left')
#circle-left(hidden, data-view="circle-left")
include ../circle/page-circle-left.pug
#admin-circle-list(hidden, data-view="admin-circle-list")
solid-widget(name='hubl-circle-owner')
solid-widget(name='hubl-circle-owner')
template
solid-display.labelled-avatar.two-lines(
data-src='${await value}'
@ -27,10 +17,10 @@ solid-router(default-route='admin-circle-list', hidden)
value-at='@'
)
div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-xsmall.sm-padding-bottom-small.sm-padding-left-xsmall.border-bottom.border-color-grey.whitespace-normal
div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-xsmall.sm-padding-bottom-small.sm-padding-left-xsmall.border-bottom.border-color-grey.whitespace-normal
h2.margin-none.text-uppercase.text-xlarge.text-letter-spacing-large(data-trans='circle.list.title')
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-normal.whitespace-normal
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-normal.whitespace-normal
div#loader-admin-circles.loader.loader-top
div
@ -45,7 +35,7 @@ solid-router(default-route='admin-circle-list', hidden)
solid-ac-checker(data-src=`${endpoints.circles || (endpoints.post && endpoints.post.circles)}`, permission='acl:Append')
solid-link(
class='segment sm-full button text-xsmall text-bold text-uppercase text-center reversed color-secondary bordered icon icon-plus'
next='admin-circle-create'
next='admin-circles-create'
data-trans='circle.list.buttonCreate'
)
@ -132,6 +122,3 @@ solid-router(default-route='admin-circle-list', hidden)
order-by="name"
)
#admin-circle-create(hidden, data-view="admin-circle-create")
include page-admin-circles-create.pug

View File

@ -1,7 +1,3 @@
solid-router(default-route='admin-communities-list', hidden)
solid-route(name='admin-communities-list')
solid-route(name='admin-users-create', use-id)
solid-widget(name='hubl-action-community')
template
solid-ac-checker(data-src="${value}", nested-field="members", permission='acl:Append')
@ -14,11 +10,10 @@ solid-widget(name='hubl-action-community')
solid-ac-checker(data-src="${value}", nested-field="members", no-permission='acl:Append')
div.button.button-disabled(data-trans='communities.noPermission')
#admin-communities-list(hidden, data-view="admin-communities-list")
div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-xsmall.sm-padding-bottom-small.sm-padding-left-xsmall.border-bottom.border-color-grey.whitespace-normal
div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-xsmall.sm-padding-bottom-small.sm-padding-left-xsmall.border-bottom.border-color-grey.whitespace-normal
h2.margin-none.text-uppercase.text-xlarge.text-letter-spacing-large(data-trans='communities.title')
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-medium.whitespace-normal
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-medium.whitespace-normal
div.segment.lg-full.margin-bottom-xlarge
h3.text-color-heading.text-semibold.text-letter-spacing-large(data-trans='communities.subTitle')
@ -50,6 +45,3 @@ solid-widget(name='hubl-action-community')
div
div
div
#admin-users-create(hidden, data-view="admin-users-create")
include page-admin-users-create.pug

View File

@ -2,7 +2,7 @@ div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-
div.segment.lg-half
h2.margin-none.text-uppercase.text-xlarge.text-letter-spacing-large(data-trans='project.create.title')
div.segment.lg-half.sm-hidden.text-right
solid-link(class="backlink right", next='admin-project-list' data-trans='project.create.backlink')
solid-link(class="backlink right", next='admin-projects' data-trans='project.create.backlink')
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-medium.whitespace-normal
div#loader-projects-create.loader.loader-top

View File

@ -1,17 +1,7 @@
solid-router(default-route='admin-project-list', hidden)
solid-route(name='admin-project-list')
solid-route(name='admin-project-create')
solid-route(name='project-left')
#project-left(hidden, data-view="project-left")
include ../project/page-project-left.pug
#admin-project-list(hidden, data-view="admin-project-list")
div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-xsmall.sm-padding-bottom-small.sm-padding-left-xsmall.border-bottom.border-color-grey.whitespace-normal
div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-xsmall.sm-padding-bottom-small.sm-padding-left-xsmall.border-bottom.border-color-grey.whitespace-normal
h2.margin-none.text-uppercase.text-xlarge.text-letter-spacing-large(data-trans='project.list.title')
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-medium.whitespace-normal
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-medium.whitespace-normal
div.segment.lg-full.sm-full.margin-bottom-xlarge.whitespace-normal
div.segment.lg-half.sm-full
@ -20,7 +10,7 @@ solid-router(default-route='admin-project-list', hidden)
solid-ac-checker(data-src=`${endpoints.projects || (endpoints.post && endpoints.post.projects)}`, permission='acl:Append')
solid-link(
class='segment sm-full button text-xsmall text-bold text-uppercase text-center reversed color-secondary bordered icon icon-plus'
next='admin-project-create'
next='admin-projects-create'
data-trans='project.list.buttonCreate'
)
@ -163,5 +153,3 @@ solid-router(default-route='admin-project-list', hidden)
div
div
#admin-project-create(hidden, data-view="admin-project-create")
include page-admin-projects-create.pug

View File

@ -2,7 +2,7 @@ div.segment.lg-full.sm-full.padding-large.sm-padding-top-small.sm-padding-right-
div.segment.lg-half
h2.margin-none.text-uppercase.text-xlarge.text-letter-spacing-large(data-trans='communities.title')
div.segment.lg-half.sm-hidden.text-right
solid-link(class="backlink", bind-resources, next='admin-communities-list' data-trans='circle.create.backlink')
solid-link(class="backlink", bind-resources, next='admin-communities' data-trans='circle.create.backlink')
div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-medium.whitespace-normal
@ -31,7 +31,13 @@ div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-mediu
div.segment.margin-bottom-medium
div.segment
p.text-color-heading.text-semibold.text-xlarge.text-letter-spacing-large(data-trans='user.create.title', loader-id='loader-users-title')
solid-display.text-color-heading.text-semibold.text-xlarge.text-letter-spacing-large(
bind-resources
fields='text, name'
value-text=''
data-trans='value-text=user.create.title'
loader-id='loader-users-title'
)
solid-form.form#selected-community(
bind-resources
@ -59,7 +65,7 @@ div.segment.lg-full.sm-full.padding-large.sm-padding-xsmall.sm-padding-top-mediu
widget-user.username='hubl-username-field'
widget-user.email='hubl-email-field'
next='admin-communities-list'
next='admin-communities'
submit-button=''
data-trans='label-user.first_name=user.create.labelFirstname;label-user.last_name=user.create.labelLastname;label-user.username=user.create.labelUsername;label-user.email=user.create.labelEmail;submit-button=user.create.buttonSubmit'

View File

@ -6,6 +6,6 @@ div.text-center
p
span(data-trans='circle.left.paragraphJoin')
span &nbsp;
solid-link.link(next="admin-circle-list" data-trans='circle.left.admin')
solid-link.link(next="admin-circles" data-trans='circle.left.admin')
span &nbsp;
span(data-trans='circle.left.paragraphContact')

View File

@ -3,13 +3,13 @@ div
solid-link.segment.sm-hidden(next='dashboard')
img.logo(src=`${clientLogo || '/images/logo.webp'}`)
button.notLoggedIn.segment.lg-hidden.icon-menu#toggleMainMenu
button.segment.lg-hidden.icon-menu#toggleMainMenu
span.tag.reversed.text-semibold(data-trans='header.beta')
div
solid-notifications.segment.sm-margin-right-xlarge.notLoggedIn(
solid-notifications.segment.sm-margin-right-xlarge(
nested-field="inbox"
bind-user
)
@ -24,7 +24,7 @@ div
)
//- User menu visible on large screens
details.segment.sm-hidden.notLoggedIn
details.segment.sm-hidden.user-controls
summary.text-right
solid-display.labelled-avatar.padding-top-xsmall(
fields='segment1(account.picture), segment2(first_name), segment3(button)'
@ -51,7 +51,7 @@ div
li.segment.padding-top-small
a.icon.icon-people.icon-third.icon-small.icon-margin-right-xsmall(data-trans='admin.menuRight.community')
if endpoints.get.circles
solid-link.text-hover(next='admin')
solid-link.text-hover(next='admin-circles')
li.segment.padding-top-small
a.icon.icon-globe.icon-third.icon-small.icon-margin-right-xsmall(data-trans='admin.menuRight.circles')
if endpoints.get.projects
@ -63,7 +63,7 @@ div
li
button.segment.padding-small.text-hover.text-bold.text-color-heading(role='log out' onclick="document.querySelector('sib-auth').logout();" data-trans='header.logOut')
button.notLoggedIn.segment.lg-hidden.icon-menu#toggleMainMenu
button.segment.lg-hidden.icon-menu#toggleMainMenu
sib-auth(style='display:none!important', auto-login)
sib-auth-provider(
@ -73,7 +73,7 @@ div
)
//- User menu visible on small screens
details.user-menu.segment.lg-hidden.notLoggedIn
details.user-menu.segment.lg-hidden.user-controls
summary
solid-display.labelled-avatar(
fields='segment1(account.picture), segment3(button)'
@ -109,7 +109,7 @@ div
li.segment.padding-top-small.sm-padding-top-medium
a.icon.icon-people.icon-third.icon-small.icon-margin-right-xsmall(data-trans='admin.menuRight.community')
if endpoints.get.circles
solid-link.text-hover(next='admin')
solid-link.text-hover(next='admin-circles')
li.segment.padding-top-small.sm-padding-top-medium
a.icon.icon-globe.icon-third.icon-small.icon-margin-right-xsmall(data-trans='admin.menuRight.circles')
if endpoints.get.projects
@ -121,7 +121,7 @@ div
li
button.segment.padding-small.sm-padding-medium.sm-padding-left-xlarge.text-hover.text-bold.text-color-heading(role='log out' onclick="document.querySelector('sib-auth').logout();" data-trans='header.logOut')
button.notLoggedIn.segment.lg-hidden.icon-menu#toggleMainMenu
button.segment.lg-hidden.icon-menu#toggleMainMenu
sib-auth(style='display:none!important', auto-login)
sib-auth-provider(

View File

@ -140,13 +140,15 @@ solid-router#navbar-router(default-route='dashboard')
div.divider
if endpoints.get.projects
div.menu-wrapper
solid-link.menu.segment.lg-full.sm-full.padding-small.text-semibold.text-color-white.heading-active.bg-color-heading.hover.active(next='admin-projects')
solid-route.menu.segment.lg-full.sm-full.padding-small.text-semibold.text-color-white.heading-active.bg-color-heading.hover.active(name='admin-projects')
div.segment.margin-right-xxsmall
div.segment.icon.icon-small.icon-folder-alt
div.segment.lg-three-quarter.sm-three-quarter.text-uppercase.text-letter-spacing-large(data-trans="menuLeft.projects")
div.menu-chevron.segment
div.icon-arrow-right-circle
solid-route(name='project', rdf-type='hd:project', use-id='', hidden)
solid-route(name='admin-projects-create', hidden)
solid-route(name='project-left', hidden)
div.sub-menu.menu-notification
div#loader-projects.loader.loader-menu
div
@ -167,13 +169,15 @@ solid-router#navbar-router(default-route='dashboard')
div.divider
if endpoints.get.circles
div.menu-wrapper
solid-link.menu.segment.lg-full.sm-full.padding-small.text-semibold.text-color-white.heading-active.bg-color-heading.hover.active(next='admin')
solid-route.menu.segment.lg-full.sm-full.padding-small.text-semibold.text-color-white.heading-active.bg-color-heading.hover.active(name='admin-circles')
div.segment.margin-right-xxsmall
div.segment.icon.icon-small.icon-folder-alt
div.segment.lg-three-quarter.sm-three-quarter.text-uppercase.text-letter-spacing-large(data-trans="menuLeft.circles")
div.menu-chevron.segment
div.menu-icon.icon-arrow-right-circle
solid-route(name='circle', rdf-type='hd:circle', use-id='', hidden)
solid-route(name='admin-circles-create')
solid-route(name='circle-left')
div.sub-menu.menu-notification
div#loader-circles.loader.loader-menu
div
@ -193,12 +197,13 @@ solid-router#navbar-router(default-route='dashboard')
)
div.divider
div.menu-wrapper
div.menu.segment.lg-full.sm-full.padding-small.text-semibold.text-color-white.heading-active.bg-color-heading.hover.active
solid-route.menu.segment.lg-full.sm-full.padding-small.text-semibold.text-color-white.heading-active.bg-color-heading.hover.active(name='admin-communities')
div.segment.margin-right-xxsmall
div.segment.icon.icon-small.icon-envelope-letter
div.segment.icon.icon-small.icon-folder-alt
div.segment.lg-three-quarter.sm-three-quarter.text-uppercase.text-letter-spacing-large(data-trans="menuLeft.messages")
div.menu-chevron.segment
div.icon-arrow-up
div.menu-icon.icon-arrow-right-circle
solid-route(name='admin-users-create', use-id='', hidden)
solid-route(name='messages', rdf-type='foaf:user', use-id='', hidden)
div.sub-menu.menu-notification
div#loader-messages.loader.loader-menu
@ -222,6 +227,5 @@ solid-router#navbar-router(default-route='dashboard')
)
div.divider
solid-route(name='admin', hidden)
solid-route.menu(name='profile', hidden)
solid-route(name='about', hidden)

View File

@ -1,4 +1,5 @@
//- Templates for notifications
include notifications/message-circle.pug
include notifications/message-project.pug
include notifications/message-private.pug

View File

@ -0,0 +1,11 @@
solid-notifications-template(data-rdf-type='hd:project')
template
.solid-notification__avatar
| ${await author['account.foaf:depiction'] ? `<img src="${await author['account.foaf:depiction']}" style="max-width:100%; max-height: 100%;" />` : `<img src="/images/alien.webp" />`}
.solid-notification__content
.solid-notification__title ${await author.name}
span.solid-notification__title__side
span(data-trans='notification.circle.in')
span.solid-notification__title__icon ${(await object.status) == 'Public' ? '#' : ''}
| ${await object.name}
p.solid-notification__summary ${summary}

View File

@ -7,6 +7,6 @@
p
span(data-trans='project.left.paragraphJoin')
span &nbsp;
solid-link.link(next="admin-project-list" data-trans='project.left.admin')
solid-link.link(next="admin-projects" data-trans='project.left.admin')
span &nbsp;
span(data-trans='project.left.paragraphContact')