app: Recherche ⩾ 1 ligne & graphe vide

This commit is contained in:
Mattéo Delabre 2019-12-02 00:19:07 -05:00
parent 4295a94edf
commit 2f5674284c
Signed by: matteo
GPG Key ID: AE3FBD02DC583ABB
2 changed files with 25 additions and 3 deletions

View File

@ -273,6 +273,10 @@ const Graph = ({nodes, edges, render}) =>
className="Graph_node"
>{render(id)}</span>
))}
{nodes.length === 0
? <span className="Graph_empty">Aucun résultat</span>
: null}
</div>
);
};

View File

@ -81,6 +81,7 @@ input
.TermInput
{
display: flex;
flex-wrap: wrap;
align-items: center;
border: 2px solid var(--color-dark);
@ -102,12 +103,17 @@ input
.TermInput_term
{
display: inline-block;
background: var(--color-secondary);
color: var(--color-light);
border-radius: 2px;
padding: calc(.25 * var(--base-size)) calc(.5 * var(--base-size));
margin-left: calc(.3 * var(--base-size));
margin:
calc(.25 * var(--base-size))
0
calc(.25 * var(--base-size))
calc(.25 * var(--base-size));
background: var(--color-secondary);
color: var(--color-light);
cursor: pointer;
transition: background var(--animation-short) var(--animation-ease-out);
@ -164,6 +170,18 @@ input
transform: translate(-50%, -50%);
}
.Graph_empty
{
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
font-size: var(--font-size-larger);
font-style: italic;
color: var(--color-dark-lighter);
}
/**
* SearchResults
*/