Merge branch 'staging' into gm-missing-edit-circle

This commit is contained in:
Jean-Baptiste Pasquier 2019-10-24 16:22:06 +02:00
commit a71fbf1b78
No known key found for this signature in database
GPG Key ID: F2702E6D22ED4D62
12 changed files with 141 additions and 385 deletions

View File

@ -1,299 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>HD App</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="icon" type="image/png" href="/images/favicon.png">
<script type="module" src="https://unpkg.com/@startinblox/oidc@0.6.0"></script>
<script src="/scripts/index.js"></script>
<link rel="stylesheet" href="/styles/index.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Open+Sans:300,400,400i,600,700&amp;amp;subset=latin-ext">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Open+Sans:300,300i,400,400i,600,600i,700,700i,800,800i">
<script type="module" src="https://unpkg.com/@startinblox/core@0.7"></script>
<script type="module" src="https://unpkg.com/@startinblox/router@0.7.2"></script>
<script type="module" src="https://unpkg.com/@startinblox/component-chat@0.1.7"></script>
<script type="module" src="https://unpkg.com/@startinblox/component-notifications@0.1.12"></script>
<script type="module" src="https://unpkg.com/@startinblox/component-conversation@0.2.1"></script>
<script type="module" src="https://unpkg.com/@startinblox/component-directory@0.1.16"></script>
</head>
<body>
<header id="header" role="banner">
<div id="logo">
<sib-link next="members"><img src="/images/logo.png" width="111" height="32"></sib-link>
</div>
<sib-notifications id-suffix="inbox" bind-user></sib-notifications>
<sib-widget name="hd-user-avatar">
<template><img name="${name}" src="${value || '/images/alien.jpg'}" style="max-width:100%; max-height: 100%;"></template>
</sib-widget>
<details id="user-controls">
<summary tabindex="0" role="button">
<sib-display id="user-controls__profile" data-fields="first_name, account.picture" widget-account.picture="hd-user-avatar" bind-user></sib-display>
</summary>
</details>
<button role="log in" onclick="document.querySelector('sib-auth').login();">Login</button>
<sib-auth>
<sib-auth-provider class="sib-auth-provider" data-authority="https://api.test-nantes.happy-dev.fr/openid/" data-client_id="621272" data-id="paris" data-response_type="id_token token" data-scope="openid profile email" data-automaticSilentRenew="true" data-loadUserInfo="true"></sib-auth-provider>
</sib-auth>
</header>
<main>
<nav id="main__menu">
<sib-router id="navbar-router" default-route="members">
<sib-route class="menu" name="members">
<div class="menu-label">Members</div>
<div class="menu-icon icon-people"></div>
</sib-route>
<div class="divider"></div>
<sib-route class="menu" name="job-offers" rdf-type="hd:joboffer">
<div class="menu-label">Job offers</div>
<div class="menu-icon icon-briefcase"></div>
</sib-route>
<sib-route hidden name="job-offer-create"></sib-route>
<div class="divider"></div>
<div class="menu-wrapper">
<div class="menu">
<div class="menu-chevron">
<div class="menu-icon icon-arrow-up"></div>
</div>
<div class="menu-label">Projects</div>
<div class="menu-icon icon-folder-alt"></div>
</div>
<sib-route hidden name="project" id-prefix="https://api.test-nantes.happy-dev.fr/projects/" rdf-type="hd:project" use-id=""></sib-route>
<div class="sub-menu">
<sib-display data-src="https://api.test-nantes.happy-dev.fr/projects/" data-fields="project" set-project="customer.name, dash, name" value-dash=" - " next="project"></sib-display>
</div>
</div>
<div class="divider"></div>
<div class="menu-wrapper">
<div class="menu">
<div class="menu-chevron">
<div class="menu-icon icon-arrow-up"></div>
</div>
<div class="menu-label">Chat</div>
<div class="menu-icon icon-envelope-letter"></div>
</div>
<sib-route hidden name="member-chat" id-prefix="https://api.test-nantes.happy-dev.fr/members/" rdf-type="foaf:user" use-id=""></sib-route>
<div class="sub-menu">
<sib-display data-src="https://api.test-nantes.happy-dev.fr/members/" data-fields="user.username" widget-user.username="sib-display-div" next="member-chat"></sib-display>
</div>
</div>
<div class="divider"></div>
</sib-router>
</nav>
<div id="viewport">
<div class="no-sidebar" id="members" hidden>
<sib-directory data-src="https://api.test-nantes.happy-dev.fr/members/" range-groups="https://api.test-nantes.happy-dev.fr/groups/" range-skills="https://api.test-nantes.happy-dev.fr/skills/"></sib-directory>
</div>
<div class="no-sidebar" id="job-offers" hidden>
<div class="job-offers__main">
<sib-widget name="hd-user-avatar">
<template><img name="${name}" src="${value || '/images/alien.jpg'}" style="max-width:100%; max-height: 100%;"></template>
</sib-widget>
<sib-widget name="groups-name">
<template>${value.name}</template>
</sib-widget>
<sib-widget name="skills-name">
<template>
<li class="skill">${value.name}</li>
</template>
</sib-widget>
<sib-widget name="joboffers-filter">
<template>
<select>
<option name="Offers" disabled>Offers</option>
<option selected name="Current offers">Current offers</option>
<option name="Expired offers">Expired offers</option>
<option name="All offers">All offers</option>
<option name="My offers">Only my offers</option>
</select>
</template>
</sib-widget>
<sib-widget name="hd-contact-author">
<template>
<sib-link next="member-chat" data-src="${value.profile['@id']}">Send a message</sib-link>
</template>
</sib-widget>
<div class="job-offers__content">
<h1>New offers<span>Here you can find and post offers</span></h1>
<sib-display id="offers-list" data-src="https://api.test-nantes.happy-dev.fr/job-offers/" data-fields="user-thumb, creationDate, title, description, skills, author" set-user-thumb="author.account.picture, author.first_name, author.groups" widget-author.account.picture="hd-user-avatar" widget-author.groups="groups-name" multiple-author.groups widget-skills="skills-name" multiple-skills widget-author="hd-contact-author" search-range-skills="https://api.test-nantes.happy-dev.fr/skills/" search-fields="content, open, skills" set-content="title, description" search-label-content="Search by keyword" search-label-skills="Search by skills" search-widget-content="sib-form-placeholder-text" search-widget-skills="sib-form-placeholder-dropdown" search-widget-open="joboffers-filter"></sib-display>
</div>
<div class="job-offers__newoffer">
<template id="groups-list-template">
<p>${value}</p>
</template>
<sib-link class="plus-button" next="job-offer-create">
<div class="icon-plus"></div>
<div>Post a new offer</div>
</sib-link>
</div>
</div>
</div>
<div class="no-sidebar" id="job-offer-create" hidden>
<sib-link class="backlink" next="job-offers">Back</sib-link>
<div class="content-box with-form">
<h1>Post a new job offer</h1>
<p class="center">This form allows you to share an offer to all members of the network.</p>
<sib-widget name="title-text">
<template>
<p>Be clear and specific with the name of your offer. You can indicate which skill is important, the start date or the name of the client. Ex: "Looking for a plumber for planet Mars ASAP".</p>
</template>
</sib-widget>
<sib-widget name="description-text">
<template>
<p>Be specific and exhaustive to avoid answering too many questions later. Indicate what is the best way to fill the offer, the prerequisites...'</p>
</template>
</sib-widget>
<sib-form class="block" data-src="https://api.test-nantes.happy-dev.fr/job-offers/" range-skills="https://api.test-nantes.happy-dev.fr/skills/" data-fields="title, title-text, description, description-text, skills" label-title="Title*" widget-title-text="title-text" label-description="Description*" widget-description-text="description-text" label-skills="The required skills for this mission:*" multiple-skills="sib-multiple-select" widget-skills="sib-form-auto-completion" next="job-offers"></sib-form>
</div>
</div>
<div class="with-sidebar" id="project" hidden>
<div class="views-container">
<div id="project-chat">
<div class="content-box full-width chat-view">
<sib-chat data-authentication="login" data-auto-login="true" data-bosh-service-url="https://jabber.happy-dev.fr/http-bind/" data-debug="false" data-locales-url="en" bind-resources></sib-chat>
</div>
</div>
<div id="project-profile">
<div class="content-box full-width">
<sib-widget name="template-business-provider">
<template>
<ul>
<li><span>Happy Dev Paris:</span> 5%</li>
<li><span>Business provider:</span> ${value.name}, ${value.fee ? value.fee:0}%</li>
</ul>
</template>
</sib-widget>
<sib-widget name="customer-template">
<template>
<div id="clientBox">
<div>
<h5>Client:</h5>
<ul>
<li><span>Business name:</span>${value.name}</li>
<li><span>Company register:</span>${value.companyRegister}</li>
<li><span>Address:</span><br>
<p>${value.address}</p>
</li>
</ul>
</div>
<div>
<h5>Contact:</h5>
<ul>
<li class="mdi-account-outline"><span>${value.firstName} ${value.lastName}</span>, ${value.role}</li>
<li class="mdi-email-outline"><a href="mailto:${value.email}">${value.email}</a></li>
<li class="mdi-cellphone-iphone">${value.phone}</li>
</ul>
</div>
</div>
</template>
</sib-widget>
<sib-widget name="hd-user-avatar">
<template><img name="${name}" src="${value || '/images/alien.jpg'}" style="max-width:100%; max-height: 100%;"></template>
</sib-widget>
<sib-widget name="team-template">
<template>
<sib-display data-src="${value.user['@id']}" data-fields="account.picture" widget-account.picture="hd-user-avatar"></sib-display>
<div name="user.thumb"><span>${value.user.name}</span>
<sib-display data-src="${value.user.groups['@id']}" data-fields="name" multiple-name></sib-display>
</div><span>${value.name}</span>
</template>
</sib-widget>
<sib-display data-fields="block-title, infos, block-lead, block-fee, block-customer, block-team" set-block-title="const-title1, number, customer.name, const-title2, name, entitled, creationDate" value-const-title1="N°" value-const-title2="-" value-entitled="Creation date:" set-infos="block-description, block-logo" set-block-description="label-description, description" set-block-logo="customer.logo" value-label-description="DESCRIPTION:" widget-customer.logo="sib-display-img" set-block-fee="label-fee, businessProvider" value-label-fee="FEE:" widget-businessProvider="template-business-provider" set-block-customer="label-customer, customer" value-label-customer="CUSTOMER INFORMATIONS:" widget-customer="customer-template" set-block-team="label-team, members" value-label-team="TEAM:" widget-members="team-template" multiple-members="" bind-resources></sib-display>
</div>
</div>
<div id="project-edit">
<div class="content-box with-form full-width">
<h1>Edit your project</h1>
<p>Here you can edit your projet's details</p>
<sib-widget name="hd-template-project-title">
<template><span>${label}</span></template>
</sib-widget>
<sib-widget name="template-members">
<template>
<sib-form class="team is-horizontal" naked data-src="${id}" data-fields="user.name, name" range-user.name="https://api.test-nantes.happy-dev.fr/users/" class-name="field" class-user.name="field" label-name="Role" label-user.name="Member(s)"></sib-form>
</template>
</sib-widget>
<sib-form class="block" data-fields="block-project__info, block-project__fee, block-project__customer, block-project__team" set-block-project__info="customer.name, name, customer.logo, description" label-customer.name="Customer's name" label-name="Project's name" label-customer.logo="Customer's logo" label-description="Project description" set-block-project__fee="fieldset-fee, businessProvider, businessProvider.fee" range-businessProvider="https://api.test-nantes.happy-dev.fr/businessproviders/" label-businessProvider="Business provider" label-businessProvider.fee="Amount of the contribution (%)" widget-fieldset-fee="hd-template-project-title" widget-businessProvider.fee="sib-form-number" label-fieldset-fee="Fee" set-block-project__customer="fieldset-customer, customer.companyRegister, customer.address, customer.firstName, customer.lastName, customer.role, customer.email, customer.phone" label-customer.companyRegister="Company registration number" label-customer.address="Address" label-customer.firstName="Name of the contact at the customer's premises" label-customer.lastName="Firstname of the contact at the customer's premises" label-customer.role="Role within the company" label-customer.email="Email" label-customer.phone="Phone" widget-fieldset-customer="hd-template-project-title" label-fieldset-customer="Customer information" set-block-project__team="fieldset-team, members" label-fieldset-team="The team" widget-fieldset-team="hd-template-project-title" widget-members="template-members" multiple-members bind-resources></sib-form>
</div>
</div>
<div id="project-create">
<div class="content-box with-form full-width">
<h1>New project</h1>
<p>Here you can create your project, add members and assign them a job.</p>
<sib-form class="block" data-src="https://api.test-nantes.happy-dev.fr/projects/" range-members="https://api.test-nantes.happy-dev.fr/members/" range-team="https://api.test-nantes.happy-dev.fr/users/" data-fields="block-project__info, block-project__fee, block-project__customer" set-block-project__info="customer.name, name, customer.logo, description" label-customer.name="Customer's name" label-name="Project's name" label-customer.logo="Customer's logo" label-description="Project description" set-block-project__fee="fieldset-fee, businessProvider, businessProviderFee" widget-fieldset-fee="hd-template-project-title" label-businessProvider="Business provider" label-businessProviderFee="Amount of the contribution" set-block-project__customer="fieldset-customer, customer.companyRegister, customer.address, customer.firstName, customer.lastName, customer.role, customer.email, customer.phone" widget-fieldset-customer="hd-template-project-title" label-customer.companyRegister="Company register" label-customer.address="Address" label-customer.firstName="Name of the contact at the customer's premises" label-customer.lastName="Firstname of the contact at the customer's premises" label-customer.role="Role within the company" label-customer.email="Email" label-customer.phone="Phone"></sib-form>
</div>
</div>
</div>
<nav class="jsRightMenu" role="navigation">
<sib-router default-route="project-chat">
<ul>
<li class="jsOffsiteToggle"><a>Fold menu</a></li>
<sib-route name="project-chat" use-id>
<li> <a>Chat</a></li>
</sib-route>
<sib-route name="project-profile" use-id>
<li> <a>Information</a></li>
</sib-route>
<sib-route name="project-edit" use-id></sib-route>
<sib-route name="project-create" use-id></sib-route>
</ul>
</sib-router>
</nav>
</div>
<div class="with-sidebar" id="circle" hidden>
<div class="views-container">
<div id="circle-chat">
<div class="content-box full-width chat-view">
<sib-chat data-authentication="login" data-auto-login="true" data-bosh-service-url="https://jabber.happy-dev.fr/http-bind/" data-debug="false" data-locales-url="en" bind-resources></sib-chat>
</div>
</div>
<div id="circle-profile">
<div class="content-box full-width">
<h2>Channel's name:</h2>
<sib-display data-fields="name" bind-resources></sib-display>
<h2>Description:</h2>
<sib-display data-fields="description" bind-resources></sib-display>
<h2>In group:</h2>
<sib-display class="block-group" id-suffix="team" data-fields="teammate-img, teammate-name, teammate-pseudonym, teammate-profile, teammate-contact" set-teammate-img="account.picture" set-teammate-pseudonym="before-pseudo, username" set-teammate-name="name" template-teammate-contact="chat-link" value-before-pseudo="@" value-teammate-contact="Send a message" value-teammate-profile="View profile" widget-account.picture="sib-display-img" next="member" bind-resources></sib-display>
</div>
</div>
<div id="circle-edit">
<div class="content-box with-form full-width" id="circle-edit">
<h1>Edit group</h1>
<sib-form class="block" range-owner="https://api.test-nantes.happy-dev.fr/members/" data-fields="name, description, owner, team, jabberID, jabberRoom" range-team="https://api.test-nantes.happy-dev.fr/members/" widget-team="sib-form-multiple-dropdown" bind-resources></sib-form>
</div>
</div>
<div id="circle-create">
<div class="content-box with-form full-width">
<h1>New group</h1>
<p>Here you can create a new group according to your interests, what you want to share, etc.</p>
<sib-form data-src="https://api.test-nantes.happy-dev.fr/circles/" range-owner="https://api.test-nantes.happy-dev.fr/users/" range-team="https://api.test-nantes.happy-dev.fr/members/" data-fields="name, description, description-text, owner, owner-text, team, team-text, jabberRoom, foaf:jabberID" label-name="Channel's name" label-description="Description" label-owner="Owner of this channel" label-foaf:jabberID="Chatroom id" label-team="Member(s) of this channel" value-description-text="You can write a short description like &quot;Here, we are like Pinky and the Brain, we talk about strategy to conquer the world&quot;." value-owner-text="The one who will admin this channel" value-team-text="Add any members as you want." widget-description="sib-form-textarea" widget-jabberRoom="sib-form-checkbox" widget-team="sib-form-multiple-dropdown"></sib-form>
</div>
</div>
</div>
<nav class="jsRightMenu" role="navigation">
<sib-router default-route="circle-chat">
<ul>
<li class="jsOffsiteToggle"><a>Fold menu</a></li>
<sib-route name="circle-chat">
<li><a>Chat</a></li>
</sib-route>
<sib-route name="circle-profile">
<li><a>Information</a></li>
</sib-route>
<sib-route name="circle-edit"></sib-route>
<sib-route name="circle-create"></sib-route>
</ul>
</sib-router>
</nav>
</div>
<div class="with-sidebar" id="member-chat" hidden>
<div class="content-box full-width chat-view">
<sib-chat data-authentication="login" data-auto-login="true" data-bosh-service-url="https://jabber.happy-dev.fr/http-bind/" data-debug="false" data-locales-url="en" bind-resources></sib-chat>
</div>
</div>
</div>
</main>
</body>
</html>

View File

@ -3,6 +3,7 @@
"cdn": "https://cdn.happy-dev.fr", "cdn": "https://cdn.happy-dev.fr",
"xmpp": "https://jabber.happy-dev.fr/http-bind/", "xmpp": "https://jabber.happy-dev.fr/http-bind/",
"authority": "http://127.0.0.1:8000/openid/", "authority": "http://127.0.0.1:8000/openid/",
"clientName": "SIB App",
"endpoints": { "endpoints": {
"businessproviders": "http://127.0.0.1:8000/businessproviders/", "businessproviders": "http://127.0.0.1:8000/businessproviders/",
"circles": "http://127.0.0.1:8000/circles/", "circles": "http://127.0.0.1:8000/circles/",
@ -18,6 +19,7 @@
"cdn": "https://cdn.happy-dev.fr", "cdn": "https://cdn.happy-dev.fr",
"xmpp": "https://jabber.happy-dev.fr/http-bind/", "xmpp": "https://jabber.happy-dev.fr/http-bind/",
"authority": "https://api.alpha.happy-dev.fr/openid/", "authority": "https://api.alpha.happy-dev.fr/openid/",
"clientName": "SIB App",
"endpoints": { "endpoints": {
"businessproviders": "https://api.alpha.happy-dev.fr/businessproviders/", "businessproviders": "https://api.alpha.happy-dev.fr/businessproviders/",
"circles": "https://api.alpha.happy-dev.fr/circles/", "circles": "https://api.alpha.happy-dev.fr/circles/",
@ -34,6 +36,7 @@
"cdn": "https://cdn.happy-dev.fr", "cdn": "https://cdn.happy-dev.fr",
"xmpp": "https://jabber.happy-dev.fr/http-bind/", "xmpp": "https://jabber.happy-dev.fr/http-bind/",
"authority": "https://api.test-paris.happy-dev.fr/openid/", "authority": "https://api.test-paris.happy-dev.fr/openid/",
"clientName": "SIB App",
"endpoints": { "endpoints": {
"businessproviders": "https://api.test-paris.happy-dev.fr/businessproviders/", "businessproviders": "https://api.test-paris.happy-dev.fr/businessproviders/",
"circles": "https://api.test-paris.happy-dev.fr/circles/", "circles": "https://api.test-paris.happy-dev.fr/circles/",
@ -49,6 +52,7 @@
"cdn": "https://cdn.happy-dev.fr", "cdn": "https://cdn.happy-dev.fr",
"xmpp": "https://jabber.happy-dev.fr/http-bind/", "xmpp": "https://jabber.happy-dev.fr/http-bind/",
"authority": "https://api.test-nantes.happy-dev.fr/openid/", "authority": "https://api.test-nantes.happy-dev.fr/openid/",
"clientName": "SIB App",
"endpoints": { "endpoints": {
"businessproviders": "https://api.test-nantes.happy-dev.fr/businessproviders/", "businessproviders": "https://api.test-nantes.happy-dev.fr/businessproviders/",
"circles": "https://api.test-nantes.happy-dev.fr/circles/", "circles": "https://api.test-nantes.happy-dev.fr/circles/",

6
src/context.jsonld Normal file
View File

@ -0,0 +1,6 @@
{
"inbox": "http://happy-dev.fr/owl/#inbox",
"object": "http://happy-dev.fr/owl/#object",
"author": "http://happy-dev.fr/owl/#author"
}

View File

@ -18,7 +18,11 @@ link(rel='stylesheet', href='https://fonts.googleapis.com/css?family=Open+Sans:3
script(type="module" src="https://unpkg.com/@startinblox/core@0.9") script(type="module" src="https://unpkg.com/@startinblox/core@0.9")
script(type="module" src="https://unpkg.com/@startinblox/router@0.7") script(type="module" src="https://unpkg.com/@startinblox/router@0.7")
script(type="module" src="https://unpkg.com/@startinblox/component-chat@0.4") script(type="module" src="https://unpkg.com/@startinblox/component-chat@0.4")
//- script(type="module" src="https://unpkg.com/@startinblox/component-notifications@0.2") script(type="module" src="https://unpkg.com/@startinblox/component-notifications@0.3")
//- script(type="module" src="https://unpkg.com/@startinblox/component-conversation@0.3") //- script(type="module" src="https://unpkg.com/@startinblox/component-conversation@0.3")
//- script(type="module" src="https://unpkg.com/@startinblox/component-directory@0.3") //- script(type="module" src="https://unpkg.com/@startinblox/component-directory@0.3")
//- script(type="module" src="https://unpkg.com/@startinblox/component-job-board@0.3") //- script(type="module" src="https://unpkg.com/@startinblox/component-job-board@0.3")
//- Context - Fix for LDFlex
script(data-default-context, type="application/ld+json")
include context.jsonld

View File

@ -17,7 +17,8 @@ include templates/hd-user-avatar.pug
details#user-controls details#user-controls
summary(tabindex='0' role='button') summary(tabindex='0' role='button')
sib-display#user-controls__profile( sib-display#user-controls__profile(
fields='first_name, account.picture' fields='firstName, account.picture'
extra-context='{firstName:"first_name"}'
widget-account.picture='hd-user-avatar' widget-account.picture='hd-user-avatar'
bind-user bind-user
) )
@ -30,5 +31,6 @@ sib-auth
sib-auth-provider( sib-auth-provider(
data-authority=`${authority}` data-authority=`${authority}`
data-id=`${authorityName || "paris"}` data-id=`${authorityName || "paris"}`
data-client-name=`${clientName || "SIB App"}`
) )

View File

@ -32,6 +32,10 @@ nav#main__menu
//- empty-widget='hd-create' //- empty-widget='hd-create'
//- empty-value='project' //- empty-value='project'
//- value-dash=' - ' //- value-dash=' - '
//- search-fields='team'
//- search-widget-team='sib-form-hidden'
//- search-value-team='-'
//- set-user-id='search-value-team'
//- widget-badge='hd-counter' //- widget-badge='hd-counter'
//- action-badge='badge' //- action-badge='badge'
//- ) //- )
@ -54,7 +58,7 @@ nav#main__menu
action-badge='badge' action-badge='badge'
search-fields='team' search-fields='team'
search-widget-team='sib-form-hidden' search-widget-team='sib-form-hidden'
search-value-team='' search-value-team='-'
set-user-id='search-value-team' set-user-id='search-value-team'
order-by='name' order-by='name'
next='circle' next='circle'

View File

@ -3,9 +3,10 @@
include templates/template-business-provider.pug include templates/template-business-provider.pug
include templates/template-customer.pug include templates/template-customer.pug
include templates/template-team.pug include templates/template-team.pug
include templates/template-captain.pug
sib-display( sib-display(
fields='block-title(const-title1, number, customer.name, const-title2, name, entitled, creationDate), infos(block-description(label-description, description), block-logo(customer.logo)), block-lead, block-fee(label-fee, businessProvider), block-customer(label-customer, customer), block-team(label-team, members)', fields='block-title(const-title1, number, customer.name, const-title2, name, entitled, creationDate), infos(block-description(label-description, description), block-logo(customer.logo)), block-lead, block-fee(label-fee, businessProvider), block-customer(label-customer, customer), block-captain(label-captain, captain), block-team(label-team, members)',
value-const-title1='N°', value-const-title1='N°',
value-const-title2='-', value-const-title2='-',
@ -20,10 +21,12 @@
value-label-customer='CUSTOMER INFORMATIONS:', value-label-customer='CUSTOMER INFORMATIONS:',
widget-customer='customer-template', widget-customer='customer-template',
value-label-captain='CAPTAIN:',
widget-captain='captain-template',
value-label-team='TEAM:', value-label-team='TEAM:',
widget-members='team-template', widget-members='team-template',
multiple-members='', multiple-members,
bind-resources bind-resources
) )

View File

@ -156,7 +156,7 @@
width: 45%; width: 45%;
} }
sib-display-value[name='first_name'] { sib-display-value[name='firstName'] {
@include icon('arrow-down'); @include icon('arrow-down');
align-items: center; align-items: center;
display: flex; display: flex;
@ -224,7 +224,7 @@
div { div {
sib-display-value[name='first_name'] { sib-display-value[name='firstName'] {
@include icon('close'); @include icon('close');
&::before { &::before {

View File

@ -75,7 +75,7 @@ sib-job-board {
margin: 0.25em; margin: 0.25em;
} }
[name='author.first_name'] { [name='author.firstName'] {
color: $color-0-0-29; color: $color-0-0-29;
font-weight: 600; font-weight: 600;
} }

View File

@ -98,9 +98,7 @@
#clientBox { #clientBox {
display: flex; display: flex;
margin-left: auto; margin: 1.7rem auto;
margin-right: auto;
margin-top: 1.7rem;
max-width: 100%; max-width: 100%;
>* { >* {
@ -166,21 +164,12 @@
} }
} }
[name='block-team'] { [name='block-team'], [name='block-captain'] {
>sib-multiple {
label { label {
display: none; display: none;
} }
>team-template[name='members'] { sib-display.project-profile-user-avatar {
display: grid;
grid-column-gap: 1.6rem;
grid-template-columns: 7vh auto;
grid-template-rows: repeat(2, 5.2vh);
>sib-display:first-child {
align-self: center; align-self: center;
grid-column: 1 / span 1; grid-column: 1 / span 1;
grid-row: 1 / span 2; grid-row: 1 / span 2;
@ -204,6 +193,13 @@
} }
} }
team-template[name='members'], captain-template[name='captain'] {
display: grid;
grid-column-gap: 1.6rem;
grid-template-columns: 7vh auto;
grid-template-rows: repeat(2, 5.2vh);
> div:nth-child(2) { > div:nth-child(2) {
align-self: end; align-self: end;
display: flex; display: flex;
@ -235,6 +231,13 @@
} }
} }
} }
}
.project-profile-user-avatar {
display: inline;
* {
height: 100%;
width: 100%;
}
}
} }

View File

@ -0,0 +1,23 @@
include hd-user-avatar.pug
sib-widget(name='captain-template')
template
sib-display.project-profile-user-avatar(
data-src="${value ? value['@id'] : ''}"
fields='account.picture',
widget-account.picture='hd-user-avatar'
)
div(name='user.thumb')
sib-display(
data-src="${value ? value['@id'] : ''}"
fields='name'
)
sib-display(
data-src="${value ? value['@id'] : ''}",
fields='name'
nested-field="groups"
)
sib-display(
data-src="${value ? value['@id'] : ''}"
fields='username'
)

View File

@ -2,16 +2,22 @@ include hd-user-avatar.pug
sib-widget(name='team-template') sib-widget(name='team-template')
template template
sib-display( sib-display.project-profile-user-avatar(
data-src="${value.user['@id']}" data-src="${value.user ? value.user['@id'] : ''}"
fields='account.picture', fields='account.picture',
widget-account.picture='hd-user-avatar' widget-account.picture='hd-user-avatar'
) )
div(name='user.thumb') div(name='user.thumb')
span ${value.user.name}
sib-display( sib-display(
data-src="${value.user.groups['@id']}", data-src="${value.user ? value.user['@id'] : ''}"
fields='name', fields='name'
multiple-name )
sib-display(
data-src="${value.user ? value.user['@id'] : ''}",
fields='name'
nested-field="groups"
)
sib-display(
data-src="${value.user ? value.user['@id'] : ''}"
fields='username'
) )
span ${value.name}