Skip to content

Commit 80253a6

Browse files
committed
created first structure of cv-jedi-minimalist and his header section
1 parent eb72011 commit 80253a6

File tree

16 files changed

+323
-0
lines changed

16 files changed

+323
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
</header>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
import ejs from 'ejs';
2+
import headerElementEndTemplate from './header-element-end.ejs?raw';
3+
4+
export const generateHeaderElementEnd = (): string => ejs.render(headerElementEndTemplate);
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export * from './header-element-end.part';
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<header>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
import ejs from 'ejs';
2+
import headerElementStartTemplate from './header-element-start.ejs?raw';
3+
4+
export const generateHeaderElementStart = (): string => ejs.render(headerElementStartTemplate);
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export * from './header-element-start.part';
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<%_ if (profile && profile !== 'undefined' ) { -%>
2+
<h1><%= profile?.name %> <br /><span><%= profile?.surnames %></span></h1>
3+
<h2><%= profile?.title %></h2>
4+
<%_ } -%>
5+
6+
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
import { ManfredAwesomicCV } from '@/model';
2+
import { ProfileSectionVm, mapFromMacCvToProfileSectionVm } from '@lemoncode/manfred-common/profile-section';
3+
import headerSection from './header-section.ejs?raw';
4+
import ejs from 'ejs';
5+
6+
export const generateHeaderSection = (cv: ManfredAwesomicCV): string => {
7+
const profileSectionVm = mapFromMacCvToProfileSectionVm(cv);
8+
9+
return generateHeaderSectionInner(profileSectionVm);
10+
};
11+
12+
const generateHeaderSectionInner = (profileSectionVm: ProfileSectionVm): string => {
13+
const rootObject = {
14+
profile: profileSectionVm,
15+
};
16+
17+
return ejs.render(headerSection, rootObject);
18+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export * from './header-section.part';
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
</div>
2+
</body>
3+
</html>

0 commit comments

Comments
 (0)