parent
ebe46c6b6f
commit
dee070596a
@ -1,23 +0,0 @@
|
||||
# Documentation
|
||||
|
||||
## Define your own colors
|
||||
|
||||
We use css variables to apply colors in the application.
|
||||
|
||||
The file can be found in src/styles/etc/
|
||||
|
||||
Example of use:
|
||||
|
||||
```css
|
||||
:root {
|
||||
--color-primary: #FFD759;
|
||||
--color-secondary: #FFB700;
|
||||
--color-complementary: #3C3F57;
|
||||
--color-complementary-darken: #27293A;
|
||||
}
|
||||
```
|
||||
|
||||
Users can find example files at the root of the application. Use
|
||||
|
||||
- client.sample.happy-dev.css : for a more advanced example of customization.
|
||||
- client.sample.css : to set five basic colors and let the default setup apply the colors.
|
@ -1,282 +0,0 @@
|
||||
:root {
|
||||
--color-primary: #FFB700;
|
||||
--color-secondary: #3C3F57;
|
||||
--color-complementary: #6259E5;
|
||||
--color-complementary-darken: #36383B;
|
||||
--color-white: #FFFFFF;
|
||||
|
||||
--color-black-h: 216;
|
||||
--color-black-s: 4%;
|
||||
--color-black-l: 22%;
|
||||
|
||||
--color-main-background: var(--color-grey-13);
|
||||
--color-main-text: #7A7F85;
|
||||
--color-highlight-primary: var(--color-primary);
|
||||
--color-user-panel: var(--color-black);
|
||||
--color-bell: var(--color-secondary);
|
||||
--color-avatar-background: #E4E8ED;
|
||||
--color-title: #36383B;
|
||||
--color-h1: var(--color-title);
|
||||
--color-h2: var(--color-title);
|
||||
|
||||
/* Depreciated */
|
||||
--color-tag-group-text: #9BA0A7;
|
||||
--color-tag-group-border: var(--color-primary);
|
||||
--color-label-dark: var(--color-grey-6);
|
||||
|
||||
/* Header's elements */
|
||||
--color-header-background: var(--color-white);
|
||||
--color-bell: var(--color-complementary-darken);
|
||||
--color-notification-counter-number: black;
|
||||
--color-notification-summary: #7A7F85;
|
||||
--solid-notifications-theme: var(--color-primary);
|
||||
--color-notification-item-border: #E4E8ED;
|
||||
--color-notification-scrollbar-background: #EDF1FA;
|
||||
--color-notification-scrollbar-track: #BDC2D7;
|
||||
--color-user-panel-header-text: var(--color-complementary-darken);
|
||||
--color-user-panel-header-background: var(--color-white);
|
||||
--color-user-panel-header-text-open: var(--color-white);
|
||||
--color-user-panel-header-background-open: var(--color-secondary);
|
||||
--color-user-panel-list-background: var(--color-white);
|
||||
--color-user-panel-list-text-hover: var(--color-complementary);
|
||||
--color-user-panel-list-border: #E4E8ED;
|
||||
|
||||
/* Left menu */
|
||||
--color-menu-highlight-primary: #FFD759;
|
||||
--color-menu-background: var(--color-secondary);
|
||||
--color-menu-text: var(--color-white);
|
||||
--color-menu-text-active: var(--color-secondary);
|
||||
--color-menu-background-active: var(--color-menu-highlight-primary);
|
||||
--color-menu-badge-background: var(--color-menu-highlight-primary);
|
||||
--color-menu-badge-text-active: var(--color-menu-highlight-primary);
|
||||
--color-menu-badge-background-active: var(--color-secondary);
|
||||
--color-menu-icon-background-active: var(--color-secondary);
|
||||
|
||||
/* Right menu */
|
||||
--color-right-menu-background: #DAE2F3;
|
||||
--color-right-menu-text: var(--color-secondary);
|
||||
--color-right-menu-link-border: #BDC2D7;
|
||||
--color-right-menu-active-text: var(--color-primary);
|
||||
--color-right-menu-active-background: var(--color-secondary);
|
||||
--color-right-menu-active-icon: var(--color-primary);
|
||||
|
||||
/* Scrollbar */
|
||||
--color-scrollbar-right-background: var(--color-white);
|
||||
--color-scrollbar-right-track: var(--color-grey-6);
|
||||
--color-scrollbar-left-background: var(--color-secondary);
|
||||
--color-scrollbar-left-track: var(--color-grey-11);
|
||||
|
||||
/* Tags */
|
||||
--color-tag-admin-text: var(--color-complementary);
|
||||
--color-tag-admin-border: var(--color-complementary);
|
||||
|
||||
/* Form elements */
|
||||
--color-button-white: var(--color-white);
|
||||
--color-button-primary: var(--color-primary);
|
||||
--color-button-secondary: var(--color-complementary);
|
||||
--color-button-complementary: var(--color-secondary);
|
||||
|
||||
--color-input-background: #EDF1FA;
|
||||
--color-input-text: var(--color-secondary);
|
||||
--color-input-icon: var(--color-complementary);
|
||||
--color-input-active: var(--color-complementary);
|
||||
--color-fieldset: var(--color-title);
|
||||
--color-fieldset-border: #DAE2F3;
|
||||
--color-button-modal: var(--color-title);
|
||||
--color-select-list: var(--color-secondary);
|
||||
--color-select-add-button: var(--color-button-secondary);
|
||||
--color-select-add-button-background: var(--color-button-white);
|
||||
|
||||
--color-label-light: var(--color-grey-6);
|
||||
|
||||
/* Skill */
|
||||
--color-skill-background: var(--color-primary);
|
||||
--color-skill-text: var(--color-white);
|
||||
|
||||
/* Icon */
|
||||
--color-icon: var(--color-primary);
|
||||
|
||||
/* Table */
|
||||
--color-table-header-background: #BDC2D7;
|
||||
--color-table-header-text: var(--color-white);
|
||||
--color-table-border: #BDC2D7;
|
||||
|
||||
/* User thumb */
|
||||
--color-user-thumb-name: #7A7F85;
|
||||
|
||||
--color-backlink: var(--color-secondary);
|
||||
--color-content-header: #DAE2F3;
|
||||
|
||||
/* Chat */
|
||||
--color-chat-white: var(--color-white);
|
||||
--color-chat-primary: var(--color-primary);
|
||||
--color-chat-complementary: var(--color-complementary);
|
||||
--color-chat-secondary: var(--color-secondary);
|
||||
--color-chat-complementary-darken: var(--color-complementary-darken);
|
||||
--color-chat-grey-1: var(--color-grey-4);
|
||||
--color-chat-grey-2: var(--color-grey-6);
|
||||
--color-chat-grey-3: var(--color-grey-10);
|
||||
|
||||
/* Directory */
|
||||
--color-directory-grey-4: #7A7F85 !important;
|
||||
--color-directory-grey-5: #F0F3F6 !important;
|
||||
|
||||
--color-directory-avatar-background: #E4E8ED !important;
|
||||
--color-directory-back-link: #36383B !important;
|
||||
--color-directory-border: #DAE2F3 !important;
|
||||
--color-directory-content-header-border: #DAE2F3 !important;
|
||||
--color-directory-h1: var(--color-complementary-darken);
|
||||
--color-directory-list-icon: var(--color-primary);
|
||||
--color-directory-text: var(--color-directory-grey-4);
|
||||
|
||||
--color-directory-send-border: var(--color-complementary) !important;
|
||||
--color-directory-list-icon: var(--color-primary) !important;
|
||||
--color-directory-counter-background: var(--color-directory-grey-5) !important;
|
||||
--color-directory-counter-border: #9BA0A7 !important;
|
||||
--color-directory-counter-text: #4A4A4A !important;
|
||||
|
||||
--color-directory-paginate: #36383B !important;
|
||||
--color-directory-paginate-disabled: #9BA0A7 !important;
|
||||
|
||||
--color-directory-form-input: #EDF1FA !important;
|
||||
--color-directory-form-input-text: var(--color-directory-grey-4) !important;
|
||||
--color-directory-form-input-active: var(--color-complementary) !important;
|
||||
--color-directory-form-select-icon: var(--color-complementary) !important;
|
||||
}
|
||||
|
||||
/* Text color for the beta label */
|
||||
|
||||
#header>div.header-left>span.beta-tag {
|
||||
color: var(--color-complementary);
|
||||
}
|
||||
|
||||
/* Button to edit a channel or a project (in project-profile) */
|
||||
#project solid-link[next="project-edit"],
|
||||
#circle solid-link[next="circle-edit"] {
|
||||
background: var(--color-complementary);
|
||||
border: 1px solid var(--color-complementary);
|
||||
}
|
||||
|
||||
#project solid-link[next="project-edit"]:hover,
|
||||
#circle solid-link[next="circle-edit"]:hover {
|
||||
background: var(--color-white);
|
||||
border: 1px solid var(--color-complementary);
|
||||
color: var(--color-complementary);
|
||||
}
|
||||
|
||||
/* Button to delete a channel */
|
||||
/* box-button is depreciated */
|
||||
#circle-profile>div>div.desktop-button__end>solid-ac-checker>solid-delete,
|
||||
#circle-profile>div>div.box-button>solid-ac-checker>solid-delete {
|
||||
background: var(--color-white);
|
||||
border: 1px solid var(--color-complementary);
|
||||
color: var(--color-complementary);
|
||||
}
|
||||
|
||||
#circle-profile>div>div.desktop-button__end>solid-ac-checker>solid-delete>button,
|
||||
#circle-profile>div>div.box-button>solid-ac-checker>solid-delete>button {
|
||||
color: var(--color-complementary);
|
||||
}
|
||||
|
||||
#circle-profile>div>div.desktop-button__end>solid-ac-checker>solid-delete:hover,
|
||||
#circle-profile>div>div.box-button>solid-ac-checker>solid-delete:hover {
|
||||
background: var(--color-complementary);
|
||||
border: 1px solid var(--color-complementary);
|
||||
color: var(--color-white);
|
||||
}
|
||||
|
||||
#circle-profile>div>div.desktop-button__end>solid-ac-checker>solid-delete:hover>button,
|
||||
#circle-profile>div>div.box-button>solid-ac-checker>solid-delete:hover>button {
|
||||
color: var(--color-white);
|
||||
}
|
||||
|
||||
/* Button with a pen to edit a user */
|
||||
#admin-users-list>div>div.table>solid-display>div>solid-display>div>solid-action-hd-custom>solid-ac-checker>solid-link {
|
||||
background: var(--color-complementary);
|
||||
border: 1px solid var(--color-complementary);
|
||||
color: var(--color-white);
|
||||
}
|
||||
|
||||
#admin-users-list>div>div.table>solid-display>div>solid-display>div>solid-action-hd-custom>solid-ac-checker>solid-link:hover {
|
||||
background: var(--color-white);
|
||||
border: 1px solid var(--color-complementary);
|
||||
color: var(--color-complementary);
|
||||
}
|
||||
|
||||
/* Button to join a channel */
|
||||
#admin-circle-list>div>div.table>solid-display:nth-child(5)>div>solid-display>div>admin-circle-join-button>solid-form {
|
||||
background: var(--color-complementary);
|
||||
border: 1px solid var(--color-complementary);
|
||||
color: var(--color-white);
|
||||
}
|
||||
|
||||
#admin-circle-list>div>div.table>solid-display:nth-child(5)>div>solid-display>div>admin-circle-join-button>solid-form:hover {
|
||||
background: var(--color-white);
|
||||
border: 1px solid var(--color-complementary);
|
||||
color: var(--color-complementary);
|
||||
}
|
||||
|
||||
#admin-circle-list>div>div.table>solid-display:nth-child(5)>div>solid-display>div>admin-circle-join-button>solid-form:hover input {
|
||||
color: var(--color-complementary);
|
||||
}
|
||||
|
||||
|
||||
/* Directory - my profile*/
|
||||
|
||||
/* Colors for buttons to send a message to a member and to update or remove your profile picture */
|
||||
#member-profile>div.profile-card>div.user-profile>div>solid-display>div>solid-action.button.button-primary.bordered,
|
||||
button#solid-picture-browse.button.button-primary,
|
||||
button#solid-picture-remove.button.button-primary {
|
||||
border: 1px solid var(--color-directory-complementary) !important;
|
||||
}
|
||||
|
||||
#member-profile solid-action.button.button-primary>solid-link,
|
||||
button#solid-picture-browse.button.button-primary,
|
||||
button#solid-picture-remove.button.button-primary {
|
||||
color: var(--color-directory-complementary) !important;
|
||||
}
|
||||
|
||||
#member-profile>div.profile-card>div.user-profile>div>solid-display>div>solid-action.button.button-primary.bordered>solid-link::before {
|
||||
background-color: var(--color-directory-complementary) !important;
|
||||
}
|
||||
|
||||
/* Hover */
|
||||
#member-profile solid-action.button.button-primary:hover,
|
||||
#member-profile solid-action.button.button-primary:hover>solid-link,
|
||||
button#solid-picture-browse.button.button-primary:hover,
|
||||
button#solid-picture-remove.button.button-primary:hover {
|
||||
color: var(--color-directory-white) !important;
|
||||
background-color: var(--color-directory-complementary) !important;
|
||||
}
|
||||
|
||||
#member-profile>div.profile-card>div.user-profile>div>solid-display>div>solid-action.button.button-primary.bordered:hover>solid-link::before {
|
||||
background-color: var(--color-directory-white) !important;
|
||||
}
|
||||
|
||||
#members-list .send-display solid-link::before {
|
||||
background-color: var(--color-directory-complementary)!important;
|
||||
}
|
||||
|
||||
/* Dashboard */
|
||||
.dashboard-card>div>div>p {
|
||||
color: var(--color-complementary) !important;
|
||||
}
|
||||
|
||||
.dashboard-card .svg-color-secondary {
|
||||
fill: var(--color-complementary) !important;
|
||||
}
|
||||
|
||||
.dashboard-card i {
|
||||
border-color: var(--color-primary) !important;
|
||||
color: var(--color-complementary) !important;
|
||||
}
|
||||
|
||||
.dashboard-card sib-link, .dashboard-card solid-link {
|
||||
border-color: var(--color-complementary) !important;
|
||||
color: var(--color-complementary) !important;
|
||||
}
|
||||
|
||||
.dashboard-card sib-link:hover, .dashboard-card solid-link:hover {
|
||||
background-color: var(--color-complementary) !important;
|
||||
color: #fff !important;
|
||||
}
|
@ -1,18 +0,0 @@
|
||||
{
|
||||
"xmpp": "https://jabber.happy-dev.fr/http-bind/",
|
||||
"authority": "http://localhost:8000/",
|
||||
"clientName": "Hubl",
|
||||
"clientLogo": "https://cdn.startinblox.com/logos/hubl-logo.png",
|
||||
"endpoints": {
|
||||
"get": {
|
||||
"skills": "http://localhost:8000/skills/",
|
||||
"users": "http://localhost:8000/users/",
|
||||
"groups": "http://localhost:8000/groups/"
|
||||
},
|
||||
"post": {
|
||||
"skills": "http://localhost:8000/skills/",
|
||||
"users": "http://localhost:8000/users/",
|
||||
"groups": "http://localhost:8000/groups/"
|
||||
}
|
||||
}
|
||||
}
|
@ -1,12 +1,18 @@
|
||||
{
|
||||
"xmpp": "https://jabber.happy-dev.fr/http-bind/",
|
||||
"xmppWebsocket": "wss://jabber.happy-dev.fr/xmpp-websocket",
|
||||
"clientName": "My local Hubl",
|
||||
"clientLogo": "/images/logo.webp",
|
||||
"authority": "http://localhost:8000/",
|
||||
"authorityName": "djangoldp-server-name",
|
||||
"clientName": "Hubl",
|
||||
"clientLogo": "https://cdn.startinblox.com/logos/hubl-logo.png",
|
||||
"endpoints": {
|
||||
"groups": "http://localhost:8000/groups/",
|
||||
"skills": "http://localhost:8000/skills/",
|
||||
"users": "http://localhost:8000/users/"
|
||||
"get": {
|
||||
"skills": "http://localhost:8000/skills/",
|
||||
"users": "http://localhost:8000/users/",
|
||||
"groups": "http://localhost:8000/groups/"
|
||||
},
|
||||
"post": {
|
||||
"skills": "http://localhost:8000/skills/",
|
||||
"users": "http://localhost:8000/users/",
|
||||
"groups": "http://localhost:8000/groups/"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,24 +0,0 @@
|
||||
{
|
||||
"xmpp": "https://jabber.happy-dev.fr/http-bind/",
|
||||
"authority": "$SERVER",
|
||||
"authorityName": "djangoldp-server-name",
|
||||
"publicDirectory": true,
|
||||
"endpoints": {
|
||||
"get": {
|
||||
"circles": "$SERVER/circles/",
|
||||
"dashboards": "$SERVER/dashboards/",
|
||||
"groups": "$SERVER/groups/",
|
||||
"users": "$SERVER/users/",
|
||||
"skills": "$SERVER/skills/",
|
||||
"uploads": "$SERVER/upload/"
|
||||
},
|
||||
"post": {
|
||||
"circles": "$SERVER/circles/",
|
||||
"dashboards": "$SERVER/dashboards/",
|
||||
"groups": "$SERVER/groups/",
|
||||
"users": "$SERVER/users/",
|
||||
"skills": "$SERVER/skills/",
|
||||
"uploads": "$SERVER/upload/"
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
const HTMLAsset = require('parcel-bundler/lib/assets/HTMLAsset')
|
||||
|
||||
function shouldIgnore (file) {
|
||||
// Ignore img(src="${...}") on pug & keep the components folder pristine
|
||||
return /\${.+}/.test(file) || /components/.test(file);
|
||||
}
|
||||
|
||||
class SkipStartinbloxWidgetAsset extends HTMLAsset {
|
||||
addDependency (name, opts) {
|
||||
if (!shouldIgnore(opts.resolved)) {
|
||||
return super.addDependency(name, opts)
|
||||
}
|
||||
}
|
||||
|
||||
processSingleDependency (p, opts) {
|
||||
if (shouldIgnore(p)) return p
|
||||
else return super.processSingleDependency(p, opts)
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = SkipStartinbloxWidgetAsset
|
@ -0,0 +1,77 @@
|
||||
'use strict';
|
||||
const fs = require('fs');
|
||||
const fse = require('fs-extra');
|
||||
const Bundler = require('parcel-bundler');
|
||||
|
||||
const options = {
|
||||
outDir: './dist',
|
||||
outFile: 'index.html',
|
||||
publicUrl: '/',
|
||||
watch: process.env.NODE_ENV !== 'production',
|
||||
cache: true,
|
||||
cacheDir: '.cache',
|
||||
contentHash: false,
|
||||
minify: process.env.NODE_ENV === 'production',
|
||||
scopeHoist: false,
|
||||
target: 'browser',
|
||||
bundleNodeModules: false,
|
||||
https: true,
|
||||
logLevel: 3,
|
||||
hmr: true,
|
||||
hmrPort: 1235,
|
||||
sourceMaps: true,
|
||||
hmrHostname: '',
|
||||
detailedReport: false,
|
||||
autoInstall: true
|
||||
};
|
||||
|
||||
(async function() {
|
||||
if(!fs.existsSync("config.json")) throw "[Error] (Mandatory) Missing config.json file";
|
||||
|
||||
let config = JSON.parse(fs.readFileSync('config.json'));
|
||||
|
||||
if(!config.clientName) throw "[Error] (Mandatory) Missing clientName on config.json";
|
||||
if(!config.clientLogo) throw "[Error] (Mandatory) Missing clientLogo on config.json";
|
||||
|
||||
let manifest = {
|
||||
"lang": "fr",
|
||||
"dir": "ltr",
|
||||
"name": config.clientName,
|
||||
"description": `Hubl of ${config.clientName}`,
|
||||
"short_name": config.clientName,
|
||||
"icons": [{
|
||||
"src": config.clientLogo,
|
||||
"purpose": "any"
|
||||
}, {
|
||||
"src": "/images/hubl-icon-192.png",
|
||||
"sizes": "192x192",
|
||||
"type": "image/png"
|
||||
}, {
|
||||
"src": "/images/hubl-icon-512.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image/png"
|
||||
}],
|
||||
"start_url": ".",
|
||||
"display": "standalone",
|
||||
"orientation": "portrait",
|
||||
"background_color": "#fff",
|
||||
'theme_color': "white"
|
||||
}
|
||||
|
||||
await fse.writeJSON('./src/manifest.webmanifest', manifest)
|
||||
console.log(`Created manifest for ${config.clientName}`);
|
||||
|
||||
await fse.copy("./src/locales", "./dist/locales")
|
||||
console.log(`Copied locales to dist folder`);
|
||||
|
||||
await fse.copy("./src/components", "./dist/components")
|
||||
console.log(`Copied components to dist folder`);
|
||||
|
||||
const bundler = new Bundler('./src/index.pug', options);
|
||||
bundler.addAssetType('html', require.resolve('./assets.js'));
|
||||
if(process.env.NODE_ENV !== 'production') {
|
||||
await bundler.serve();
|
||||
} else {
|
||||
await bundler.bundle();
|
||||
}
|
||||
})();
|
@ -1,39 +0,0 @@
|
||||
'use strict';
|
||||
import fs from 'fs';
|
||||
|
||||
if(!fs.existsSync("config.json")) throw "[Error] (Mandatory) Missing config.json file";
|
||||
|
||||
let config = JSON.parse(fs.readFileSync('config.json'));
|
||||
|
||||
if(!config.clientName) throw "[Error] (Mandatory) Missing clientName on config.json";
|
||||
if(!config.clientLogo) throw "[Error] (Mandatory) Missing clientLogo on config.json";
|
||||
|
||||
let manifest = {
|
||||
"lang": "fr",
|
||||
"dir": "ltr",
|
||||
"name": config.clientName,
|
||||
"description": `Hubl of ${config.clientName}`,
|
||||
"short_name": config.clientName,
|
||||
"icons": [{
|
||||
"src": config.clientLogo,
|
||||
"purpose": "any"
|
||||
}, {
|
||||
"src": "/images/hubl-icon-192.png",
|
||||
"sizes": "192x192",
|
||||
"type": "image/png"
|
||||
}, {
|
||||
"src": "/images/hubl-icon-512.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image/png"
|
||||
}],
|
||||
"start_url": ".",
|
||||
"display": "standalone",
|
||||
"orientation": "portrait",
|
||||
"background_color": "#fff",
|
||||
'theme_color': "white"
|
||||
}
|
||||
|
||||
fs.existsSync("dist") || fs.mkdirSync("dist");
|
||||
fs.writeFileSync('dist/manifest.webmanifest', JSON.stringify(manifest, null, 2));
|
||||
|
||||
console.log(`Created manifest for ${config.clientName}`);
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,10 @@
|
||||
//- Context - Fix for default context
|
||||
script(data-default-context, type="application/ld+json")
|
||||
| {
|
||||
| "inbox": "http://happy-dev.fr/owl/#inbox",
|
||||
| "object": "http://happy-dev.fr/owl/#object",
|
||||
| "author": "http://happy-dev.fr/owl/#author",
|
||||
| "account": "http://happy-dev.fr/owl/#account",
|
||||
| "jabberID": "foaf:jabberID",
|
||||
| "picture": "foaf:depiction"
|
||||
| }
|
@ -1,5 +0,0 @@
|
||||
-
|
||||
var __env = locals[process.env.ENV]
|
||||
for(k in __env){
|
||||
eval(`var ${k} = __env[${JSON.stringify(k)}]`);
|
||||
}
|
@ -0,0 +1,2 @@
|
||||
//- Automatically import every scripts
|
||||
import './scripts/**/*.js';
|
@ -1,107 +1,134 @@
|
||||
include get_config.pug
|
||||
doctype html
|
||||
html(lang="en")
|
||||
head
|
||||
meta(charset="UTF-8")
|
||||
|
||||
title #{clientName || "My Personal Hubl"}
|
||||
|
||||
meta(name="viewport", content="width=device-width, initial-scale=1.0")
|
||||
meta(http-equiv="X-UA-Compatible", content="ie=edge")
|
||||
|
||||
if clientFavicon
|
||||
link(rel="icon" type="image/png" href=`${clientFavicon}`)
|
||||
else
|
||||
link(rel="icon" type="image/webp" href="/images/favicon.webp")
|
||||
include dependencies.pug
|
||||
link(rel="icon" type="image/webp" href="./images/favicon.webp")
|
||||
|
||||
link(rel="preconnect" href="https://fonts.gstatic.com")
|
||||
link(rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Open+Sans&display=swap")
|
||||
|
||||
link(rel='stylesheet', href='/styles/index.scss')
|
||||
|
||||
if clientCSS
|
||||
link(rel='stylesheet', href=`${clientCSS}`)
|
||||
|
||||
link(rel="manifest" href="/manifest.webmanifest")
|
||||
|
||||
script(src="https://browser.sentry-cdn.com/5.25.0/bundle.tracing.min.js" defer)
|
||||
|
||||
script(type="module" src="/components/sentry.js" defer)
|
||||
script(type="module" src="/components/hubl-search-users.js" defer)
|
||||
script(type="module" src="/components/hubl-status.js" defer)
|
||||
script(type="module" src="/components/hubl-reactivity.js" defer)
|
||||
|
||||
include dependencies.pug
|
||||
include context.pug
|
||||
|
||||
//- swal2 does not work with skypack
|
||||
script(src="https://cdn.jsdelivr.net/npm/sweetalert2@10" defer)
|
||||
|
||||
script(src="index.js" defer)
|
||||
|
||||
body
|
||||
if endpoints.get && endpoints.post
|
||||
|
||||
.wrapper
|
||||
include views/partials/notifications.pug
|
||||
include views/partials/widgets.pug
|
||||
|
||||
header#header.header.is-spaced(role='banner')
|
||||
include header.pug
|
||||
.wrapper
|
||||
|
||||
nav#main__menu.left-menu.jsLeftMenu
|
||||
include menu-left.pug
|
||||
header#header.header.is-spaced(role='banner')
|
||||
include views/partials/header.pug
|
||||
|
||||
main#viewport.content.notLoggedIn
|
||||
nav#main__menu.left-menu.jsLeftMenu
|
||||
include views/partials/menu-left.pug
|
||||
|
||||
if endpoints.dashboards || (endpoints.get && endpoints.get.dashboards)
|
||||
#dashboard(hidden, data-view="dashboard").no-sidebar.with-padding
|
||||
include page-dashboard.pug
|
||||
main#viewport.content.notLoggedIn
|
||||
|
||||
if publicDirectory && (endpoints.users || (endpoints.get && endpoints.get.users))
|
||||
#members(hidden, data-view="members").no-sidebar.with-padding
|
||||
include page-directory.pug
|
||||
if endpoints.get.dashboards
|
||||
#dashboard(hidden, data-view="dashboard").no-sidebar.with-padding
|
||||
include views/page-dashboard.pug
|
||||
|
||||
if endpoints.joboffers || (endpoints.get && endpoints.get.joboffers)
|
||||
#job-offers(hidden, data-view="job-offers").no-sidebar.with-padding
|
||||
if (endpoints.post && endpoints.post.joboffers) && (endpoints.get && endpoints.get.joboffers)
|
||||
if publicDirectory && endpoints.get.users
|
||||
#members(hidden, data-view="members").no-sidebar.with-padding
|
||||
include views/page-directory.pug
|
||||
|
||||
if endpoints.get.joboffers
|
||||
#job-offers(hidden, data-view="job-offers").no-sidebar.with-padding
|
||||
hubl-reactivity(data-src=`${endpoints.post.joboffers}current/` target-src=`${endpoints.get.joboffers}`)
|
||||
hubl-reactivity(data-src=`${endpoints.post.joboffers}expired/` target-src=`${endpoints.get.joboffers}`)
|
||||
hubl-reactivity(data-src=`${endpoints.post.joboffers}` target-src=`${endpoints.get.joboffers}`)
|
||||
hubl-reactivity(data-src=`${endpoints.joboffers || endpoints.get.joboffers}current/` target-src=`${endpoints.joboffers || endpoints.get.joboffers}`)
|
||||
hubl-reactivity(data-src=`${endpoints.joboffers || endpoints.get.joboffers}current/` target-src=`${endpoints.joboffers || endpoints.get.joboffers}expired/`)
|
||||
hubl-reactivity(data-src=`${endpoints.joboffers || endpoints.get.joboffers}expired/` target-src=`${endpoints.joboffers || endpoints.get.joboffers}`)
|
||||
hubl-reactivity(bind-user nested-field="joboffers" target-src=`${endpoints.joboffers || endpoints.get.joboffers}expired/`)
|
||||
hubl-reactivity(bind-user nested-field="joboffers" target-src=`${endpoints.joboffers || endpoints.get.joboffers}`)
|
||||
hubl-reactivity(bind-user nested-field="joboffers" target-src=`${endpoints.joboffers || endpoints.get.joboffers}current/`)
|
||||
include page-job-offers.pug
|
||||
|
||||
if endpoints.projects || (endpoints.get && endpoints.get.projects)
|
||||
#project(hidden, data-view="project").with-sidebar
|
||||
if (endpoints.post && endpoints.post.projects) && (endpoints.get && endpoints.get.projects)
|
||||
hubl-reactivity(data-src=`${endpoints.joboffers || endpoints.get.joboffers}current/` target-src=`${endpoints.joboffers || endpoints.get.joboffers}`)
|
||||
hubl-reactivity(data-src=`${endpoints.joboffers || endpoints.get.joboffers}current/` target-src=`${endpoints.joboffers || endpoints.get.joboffers}expired/`)
|
||||
hubl-reactivity(data-src=`${endpoints.joboffers || endpoints.get.joboffers}expired/` target-src=`${endpoints.joboffers || endpoints.get.joboffers}`)
|
||||
hubl-reactivity(bind-user nested-field="joboffers" target-src=`${endpoints.joboffers || endpoints.get.joboffers}expired/`)
|
||||
hubl-reactivity(bind-user nested-field="joboffers" target-src=`${endpoints.joboffers || endpoints.get.joboffers}`)
|
||||
hubl-reactivity(bind-user nested-field="joboffers" target-src=`${endpoints.joboffers || endpoints.get.joboffers}current/`)
|
||||
include views/page-job-offers.pug
|
||||
|
||||
if endpoints.get.projects
|
||||
#project(hidden, data-view="project").with-sidebar
|
||||
hubl-reactivity(data-src=`${endpoints.post.projects}joinable/` target-src=`${endpoints.get.projects}`)
|
||||
hubl-reactivity(data-src=`${endpoints.post.projects}` target-src=`${endpoints.get.projects}`)
|
||||
hubl-reactivity(bind-user nested-field="projects" target-src=`${endpoints.post.projects}`)
|
||||
hubl-reactivity(bind-user nested-field="projects" target-src=`${endpoints.post.projects}joinable/`)
|
||||
hubl-reactivity(data-src=`${endpoints.projects || endpoints.get.projects}joinable/` target-src=`${endpoints.projects || endpoints.get.projects}`)
|
||||
hubl-reactivity(bind-user nested-field="projects" target-src=`${endpoints.projects || endpoints.get.projects}`)
|
||||
hubl-reactivity(bind-user nested-field="projects" target-src=`${endpoints.projects || endpoints.get.projects}joinable/`)
|
||||
include page-project.pug
|
||||
|
||||
if endpoints.circles || (endpoints.get && endpoints.get.circles)
|
||||
#circle(hidden, data-view="circle").with-sidebar
|
||||
if (endpoints.post && endpoints.post.circles) && (endpoints.get && endpoints.get.circles)
|
||||
hubl-reactivity(data-src=`${endpoints.projects || endpoints.get.projects}joinable/` target-src=`${endpoints.projects || endpoints.get.projects}`)
|
||||
hubl-reactivity(bind-user nested-field="projects" target-src=`${endpoints.projects || endpoints.get.projects}`)
|
||||
hubl-reactivity(bind-user nested-field="projects" target-src=`${endpoints.projects || endpoints.get.projects}joinable/`)
|
||||
include views/page-project.pug
|
||||
|
||||
if endpoints.get.circles
|
||||
#circle(hidden, data-view="circle").with-sidebar
|
||||
hubl-reactivity(data-src=`${endpoints.post.circles}joinable/` target-src=`${endpoints.get.circles}`)
|
||||
hubl-reactivity(data-src=`${endpoints.post.circles}` target-src=`${endpoints.get.circles}`)
|
||||
hubl-reactivity(bind-user nested-field="circles" target-src=`${endpoints.post.circles}`)
|
||||
hubl-reactivity(bind-user nested-field="circles" target-src=`${endpoints.post.circles}joinable/`)
|
||||
hubl-reactivity(data-src=`${endpoints.circles || endpoints.get.circles}joinable/` target-src=`${endpoints.circles || endpoints.get.circles}`)
|
||||
hubl-reactivity(bind-user nested-field="circles" target-src=`${endpoints.circles || endpoints.get.circles}`)
|
||||
hubl-reactivity(bind-user nested-field="circles" target-src=`${endpoints.circles || endpoints.get.circles}joinable/`)
|
||||
include page-circle.pug
|
||||
if endpoints.users || (endpoints.get && endpoints.get.users)
|
||||
#messages(hidden, data-view="messages").with-sidebar
|
||||
include page-messages.pug
|
||||
|
||||
if endpoints.polls || (endpoints.get && endpoints.get.polls)
|
||||
#polls(hidden, data-view="polls").with-sidebar
|
||||
include page-polls.pug
|
||||
|
||||
if endpoints.events || (endpoints.get && endpoints.get.events)
|
||||
#events(hidden, data-view="events")
|
||||
include page-events.pug
|
||||
|
||||
if endpoints.resources || (endpoints.get && endpoints.get.resources)
|
||||
#resources(hidden, data-view="resources")
|
||||
include page-resources.pug
|
||||
|
||||
#admin(hidden, data-view="admin").with-sidebar
|
||||
include page-admin.pug
|
||||
|
||||
#about(data-view="about").no-sidebar.with-padding
|
||||
include page-about.pug
|
||||
|
||||
if (endpoints.skills || (endpoints.get && endpoints.get.skills)) && (endpoints.uploads || (endpoints.post && endpoints.post.uploads)) && (endpoints.users || (endpoints.post && endpoints.post.users))
|
||||
#profile(hidden, data-view="profile").no-sidebar
|
||||
include page-profile.pug
|
||||
|
||||
if analytics
|
||||
each provider in analytics
|
||||
if provider.type && provider.url && provider.url
|
||||
solid-analytics(
|
||||
type=`${provider.type}`
|
||||
url=`${provider.url}`
|
||||
id=`${provider.id}`
|
||||
)
|
||||
hubl-reactivity(data-src=`${endpoints.circles || endpoints.get.circles}joinable/` target-src=`${endpoints.circles || endpoints.get.circles}`)
|
||||
hubl-reactivity(bind-user nested-field="circles" target-src=`${endpoints.circles || endpoints.get.circles}`)
|
||||
hubl-reactivity(bind-user nested-field="circles" target-src=`${endpoints.circles || endpoints.get.circles}joinable/`)
|
||||
include views/page-circle.pug
|
||||
if endpoints.get.users
|
||||
#messages(hidden, data-view="messages").with-sidebar
|
||||
include views/page-messages.pug
|
||||
|
||||
if endpoints.get.polls
|
||||
#polls(hidden, data-view="polls").with-sidebar
|
||||
include views/page-polls.pug
|
||||
|
||||
if endpoints.get.events
|
||||
#events(hidden, data-view="events")
|
||||
include views/page-events.pug
|
||||
|
||||
if endpoints.get.resources
|
||||
#resources(hidden, data-view="resources")
|
||||
include views/page-resources.pug
|
||||
|
||||
#admin(hidden, data-view="admin").with-sidebar
|
||||
include views/page-admin.pug
|
||||
|
||||
#about(data-view="about").no-sidebar.with-padding
|
||||
include views/page-about.pug
|
||||
|
||||
if endpoints.get.skills && endpoints.post.uploads && endpoints.post.users
|
||||
#profile(hidden, data-view="profile").no-sidebar
|
||||
include views/page-profile.pug
|
||||
|
||||
if analytics
|
||||
each provider in analytics
|
||||
if provider.type && provider.url && provider.url
|
||||
solid-analytics(
|
||||
type=`${provider.type}`
|
||||
url=`${provider.url}`
|
||||
id=`${provider.id}`
|
||||
)
|
||||
else
|
||||
h1(style='color:red') Invalid config.json (missing `endpoints.get` or `endpoints.post`)
|
||||
|
@ -0,0 +1,5 @@
|
||||
const config = require("../config.json");
|
||||
|
||||
module.exports = {
|
||||
locals: config
|
||||
};
|
@ -1,28 +1,25 @@
|
||||
@charset "UTF-8";
|
||||
|
||||
@import '../../node_modules/include-media/dist/include-media';
|
||||
@import '../../node_modules/normalize.css/normalize';
|
||||
@import 'normalize.css';
|
||||
|
||||
@import 'abstracts/fonts';
|
||||
@import 'abstracts/variables';
|
||||
@import 'abstracts/mixins';
|
||||
@import 'components/loader';
|
||||
@import 'components/icons/index';
|
||||
@import 'components/icons';
|
||||
@import 'base/main';
|
||||
@import 'base/about';
|
||||
|
||||
#viewport {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
/*height: auto;
|
||||
min-height: 100vh;*/
|
||||
overflow-y: auto;
|
||||
@import 'components/index';
|
||||
@import 'layout/members/index';
|
||||
@import 'layout/job-offers/index';
|
||||
@import 'layout/user/index';
|
||||
@import 'layout/events/index';
|
||||
@import 'layout/resources/index';
|
||||
@import 'layout/dashboard/index';
|
||||
@import 'layout/polls/index';
|
||||
@import 'components';
|
||||
@import 'layout/members';
|
||||
@import 'layout/job-offers';
|
||||
@import 'layout/user';
|
||||
@import 'layout/events';
|
||||
@import 'layout/resources';
|
||||
@import 'layout/dashboard';
|
||||
@import 'layout/polls';
|
||||
}
|
||||
|
@ -1,16 +0,0 @@
|
||||
include hubl-user-avatar.pug
|
||||
|
||||
solid-widget(name='hubl-captain')
|
||||
template
|
||||
solid-display.user-thumb(
|
||||
data-src="${await value}"
|
||||
fields='account.picture, sup(name), sub(is_lead)'
|
||||
|
||||
class-account.picture='avatar user-thumb__picture'
|
||||
class-name='user-thumb__name'
|
||||
class-is_lead='user-thumb__lead'
|
||||
|
||||
widget-account.picture='hubl-user-avatar'
|
||||
value-is_lead=''
|
||||
data-trans='value-is_lead=template-captain.isLead'
|
||||
)
|
@ -1,2 +0,0 @@
|
||||
solid-widget(name='hubl-user-avatar')
|
||||
template ${await value ? `<img src="${await value}" style="max-width:100%; max-height: 100%;" />` : `<object type="image/svg+xml" data="/images/alien.svg"></object>`}
|
@ -1,13 +1,13 @@
|
||||
.views-container.sidebar-is-closed
|
||||
if endpoints.circles || (endpoints.get && endpoints.get.circles)
|
||||
#admin-circles(hidden, data-view="admin-circles")
|
||||
include views/admin/page-admin-circles.pug
|
||||
include partials/admin/page-admin-circles.pug
|
||||
if endpoints.projects || (endpoints.get && endpoints.get.projects)
|
||||
#admin-projects(hidden, data-view="admin-projects")
|
||||
include views/admin/page-admin-projects.pug
|
||||
include partials/admin/page-admin-projects.pug
|
||||
if (endpoints.users || (endpoints.get && endpoints.get.users))
|
||||
#admin-communities(hidden, data-view="admin-communities")
|
||||
include views/admin/page-admin-communities.pug
|
||||
include partials/admin/page-admin-communities.pug
|
||||
nav.jsRightMenu(role='navigation')
|
||||
solid-router(default-route='admin-circles')
|
||||
ul
|
@ -1,7 +1,5 @@
|
||||
div.content-box__info
|
||||
|
||||
include ../../templates/hubl-user-avatar.pug
|
||||
|
||||
solid-widget(name="circle-edit-members-delete")
|
||||
template
|
||||
solid-ac-checker(permission="acl:Delete" data-src="${src}")
|
@ -0,0 +1,4 @@
|
||||
//- Templates for notifications
|
||||
|
||||
include notifications/message-circle.pug
|
||||
include notifications/message-private.pug
|
@ -1,7 +1,5 @@
|
||||
div.content-box__info
|
||||
|
||||
include ../../templates/hubl-user-avatar.pug
|
||||
|
||||
solid-widget(name="project-edit-members-delete")
|
||||
template
|
||||
solid-ac-checker(permission="acl:Delete" data-src="${src}")
|
@ -0,0 +1,3 @@
|
||||
//- Import your widgets from the `widget`folder here
|
||||
|
||||
include widgets/hubl-user-avatar.pug
|
@ -0,0 +1,2 @@
|
||||
solid-widget(name='hubl-user-avatar')
|
||||
template ${value ? `<img src="${value}" style="max-width:100%; max-height: 100%;" />` : `<object type="image/svg+xml" data="/images/alien.svg"></object>`}
|
Loading…
Reference in new issue