feat: create timelint header
This commit is contained in:
parent
fc02045783
commit
d0648bea84
|
@ -0,0 +1,15 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<svg width="4.2333mm" height="4.2333mm" version="1.1" viewBox="0 0 4.2333 4.2333" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||||
|
<defs>
|
||||||
|
<linearGradient id="a" x1="122.52" x2="130.49" y1="39.199" y2="31.302" gradientTransform="translate(.09658)" gradientUnits="userSpaceOnUse">
|
||||||
|
<stop stop-color="#745cfc" offset="0"/>
|
||||||
|
<stop stop-color="#564ba4" offset="1"/>
|
||||||
|
</linearGradient>
|
||||||
|
</defs>
|
||||||
|
<g transform="matrix(.10155 0 0 .10155 -90.232 -10.197)">
|
||||||
|
<g transform="matrix(0 2.2967 -2.2967 0 990.37 -169.5)" fill="url(#a)">
|
||||||
|
<path d="m122.72 31.302 2.3682 3.7201a0.21308 0.21308 89.753 0 1 9.8e-4 0.2273l-2.4668 3.9498h1.5785a0.73492 0.73492 149.45 0 0 0.64338-0.37973l1.4732-2.6685a0.27716 0.27716 104.45 0 0 0.0345-0.13395v-1.7817a0.28946 0.28946 76.14 0 0-0.0332-0.13465l-1.2688-2.4147a0.71792 0.71792 31.14 0 0-0.63551-0.38397z"/>
|
||||||
|
<path d="m130.48 39.199-2.4404-3.8335 2.538-4.0637h-2.0122l-1.7173 3.1108v1.9246l1.5038 2.8618z"/>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 1.0 KiB |
|
@ -2,6 +2,11 @@
|
||||||
<div id='timeline'>
|
<div id='timeline'>
|
||||||
|
|
||||||
<div id='search-header' ref='header'>
|
<div id='search-header' ref='header'>
|
||||||
|
<img src='../assets/timeline/logo.svg'/>
|
||||||
|
<span>
|
||||||
|
<h3>{{ $t('timeline.title') }}</h3> <SkillCard :id='skill' :active='true'/>
|
||||||
|
</span>
|
||||||
|
<input type='button' :value="$t('timeline.back')" @click='$event.preventDefault(); scrollBack()'/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<template class='project' v-for='(proj) of projects'>
|
<template class='project' v-for='(proj) of projects'>
|
||||||
|
@ -77,6 +82,7 @@ import SkillCard from './SkillCard.vue';
|
||||||
import { Project } from '../model/projects';
|
import { Project } from '../model/projects';
|
||||||
import { tID } from '../model/skills';
|
import { tID } from '../model/skills';
|
||||||
import * as projects from '../service/projects';
|
import * as projects from '../service/projects';
|
||||||
|
import * as scroller from '../service/scroller';
|
||||||
|
|
||||||
function pluralize(n: number, s: string): string {
|
function pluralize(n: number, s: string): string {
|
||||||
n = Math.floor(Math.abs(n));
|
n = Math.floor(Math.abs(n));
|
||||||
|
@ -166,7 +172,7 @@ export default class Timeline extends Vue {
|
||||||
if ( el == null ) {
|
if ( el == null ) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// when scrolling after this limit, make the header fixed
|
// when scrolling after this limit, make the header fixed
|
||||||
const limit = el.offsetTop;
|
const limit = el.offsetTop;
|
||||||
|
|
||||||
if ( target.scrollTop >= limit ) {
|
if ( target.scrollTop >= limit ) {
|
||||||
|
@ -175,6 +181,10 @@ export default class Timeline extends Vue {
|
||||||
header.classList.remove('fixed');
|
header.classList.remove('fixed');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected scrollBack() {
|
||||||
|
scroller.go("skill-picker", 0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -187,9 +197,10 @@ export default class Timeline extends Vue {
|
||||||
$bg-color: #202228;
|
$bg-color: #202228;
|
||||||
$header-height: 6rem;
|
$header-height: 6rem;
|
||||||
$joint-height: 2rem;
|
$joint-height: 2rem;
|
||||||
|
$logo-size: 5rem;
|
||||||
|
|
||||||
#search-header {
|
#search-header {
|
||||||
display: block;
|
display: grid;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
|
@ -201,6 +212,9 @@ export default class Timeline extends Vue {
|
||||||
|
|
||||||
z-index: 500;
|
z-index: 500;
|
||||||
|
|
||||||
|
grid-template-columns: $logo-size auto min-content;
|
||||||
|
align-items: center;
|
||||||
|
|
||||||
transition: background .5s ease-in-out,
|
transition: background .5s ease-in-out,
|
||||||
margin .2s ease-in-out,
|
margin .2s ease-in-out,
|
||||||
left .2s ease-in-out,
|
left .2s ease-in-out,
|
||||||
|
@ -208,18 +222,83 @@ export default class Timeline extends Vue {
|
||||||
border-radius .2s ease-in-out,
|
border-radius .2s ease-in-out,
|
||||||
box-shadow .1s ease-in-out;
|
box-shadow .1s ease-in-out;
|
||||||
|
|
||||||
|
img {
|
||||||
|
width: $logo-size;
|
||||||
|
height: $logo-size;
|
||||||
|
|
||||||
|
opacity: 0;
|
||||||
|
|
||||||
|
margin-left: .5rem;
|
||||||
|
|
||||||
|
transition: opacity .2s ease-in-out;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
display: flex;
|
||||||
|
margin: auto;
|
||||||
|
|
||||||
|
flex-flow: row nowrap;
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
color: #fff;
|
||||||
|
font-size: 1.3em;
|
||||||
|
|
||||||
|
transition: color .2s ease-in-out;
|
||||||
|
}
|
||||||
|
|
||||||
|
.skill-card {
|
||||||
|
margin: 0 .5em;
|
||||||
|
|
||||||
|
cursor: auto;
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
background: #444952;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
input {
|
||||||
|
padding: .4em 1em;
|
||||||
|
margin-right: 1.5em;
|
||||||
|
|
||||||
|
color: #fff;
|
||||||
|
font-size: 1.4rem;
|
||||||
|
|
||||||
|
background: linear-gradient(to top right, #564ba4, #745cfc);
|
||||||
|
border: none;
|
||||||
|
border-radius: .5rem / .5rem;
|
||||||
|
|
||||||
|
opacity: 0;
|
||||||
|
transition: opacity .2s ease-in-out;
|
||||||
|
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
&.fixed {
|
&.fixed {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
left: 1rem;
|
left: 1rem;
|
||||||
width: calc( 100% - #{1*2rem} );
|
width: calc( 100% - #{1*2rem} );
|
||||||
margin-top: 1rem;
|
margin-top: 1rem;
|
||||||
|
|
||||||
background: #eee;
|
background: #fff;
|
||||||
// background: linear-gradient(to top right, #564ba4, #745cfc);
|
// background: linear-gradient(to top right, #564ba4, #745cfc);
|
||||||
border-radius: 1rem / 1rem;
|
border-radius: 1rem / 1rem;
|
||||||
|
|
||||||
box-shadow: 0 0 1em darken(#202228, 5%);
|
box-shadow: 0 0 1em darken(#202228, 5%);
|
||||||
|
|
||||||
|
img {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
color: #000;
|
||||||
|
}
|
||||||
|
|
||||||
|
input {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#timeline {
|
#timeline {
|
||||||
|
@ -239,7 +318,7 @@ export default class Timeline extends Vue {
|
||||||
|
|
||||||
padding: 0 5rem;
|
padding: 0 5rem;
|
||||||
|
|
||||||
padding-top: #{$header-height + 2rem};
|
padding-top: $header-height;
|
||||||
|
|
||||||
// line 1
|
// line 1
|
||||||
.spacer { grid-column: 2; };
|
.spacer { grid-column: 2; };
|
||||||
|
@ -418,12 +497,14 @@ export default class Timeline extends Vue {
|
||||||
color: #999999;
|
color: #999999;
|
||||||
}
|
}
|
||||||
|
|
||||||
b {
|
.name b {
|
||||||
color: #745cfc;
|
color: #745cfc;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
|
|
||||||
span {
|
.name span,
|
||||||
|
.src span,
|
||||||
|
.end span {
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
font-size: .8em;
|
font-size: .8em;
|
||||||
|
|
|
@ -9,5 +9,8 @@
|
||||||
"home.line4-2": "and",
|
"home.line4-2": "and",
|
||||||
"home.line4-3": "(Arduino, Raspberry).",
|
"home.line4-3": "(Arduino, Raspberry).",
|
||||||
|
|
||||||
|
"timeline.title": "Timeline of projects featuring",
|
||||||
|
"timeline.back": "Change skill",
|
||||||
|
|
||||||
"end": ""
|
"end": ""
|
||||||
}
|
}
|
|
@ -9,5 +9,8 @@
|
||||||
"home.line4-2": "et l'",
|
"home.line4-2": "et l'",
|
||||||
"home.line4-3": "(Arduino, Raspberry).",
|
"home.line4-3": "(Arduino, Raspberry).",
|
||||||
|
|
||||||
|
"timeline.title": "Chronologie des projets avec",
|
||||||
|
"timeline.back": "Choisir compétence",
|
||||||
|
|
||||||
"end": ""
|
"end": ""
|
||||||
}
|
}
|
Loading…
Reference in New Issue