1
0
Fork 0
curriculum-vitae/templates/cv.xsl

64 lines
2.4 KiB
XML

<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:import href="./index.xsl"/>
<xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes" standalone="yes" doctype-system="about:legacy-compat" />
<xsl:param name="title" select="'Ainsley Ellis CV'"/>
<xsl:template match="/cv" data-xmlns="http://www.w3.org/1999/xhtml">
<html lang="en" dir="ltr">
<!-- The Yesterweb is dead, long live the Yesterweb! -->
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="color-scheme" content="light dark" />
<title><xsl:value-of select="$title"/></title>
<link rel="stylesheet" href="../assets/css/all.css" />
<link rel="stylesheet" href="../assets/css/screen.css" media="screen" />
<link rel="stylesheet" href="../assets/css/print.css" media="print" />
</head>
<body>
<main>
<xsl:copy-of select="document('./fragments/header.xml')"/>
<!-- <xsl:copy-of select="/cv"/> -->
<section id="objective">
<h2>Objective</h2>
<!-- select specific objective from xml file -->
<xsl:copy-of select="document('./fragments/objectives.xml')/objectives/objective[@name='web-development']/node()"/>
</section>
<section id="work-history">
<h2>Work History</h2>
<xsl:for-each select="./work-history/company">
<xsl:call-template name="company"/>
</xsl:for-each>
</section>
<section id="open-source-contributions">
<h2>Open-source Contributions</h2>
<xsl:for-each select="./foss-contributions/project">
<xsl:call-template name="project"/>
</xsl:for-each>
</section>
<section id="education">
<h2>Education</h2>
<xsl:for-each select="./education/institution">
<xsl:call-template name="institution"/>
</xsl:for-each>
</section>
<section id="skills">
<h2>Skills</h2>
<xsl:for-each select="./skills/category">
<xsl:call-template name="skill-category"/>
</xsl:for-each>
</section>
</main>
<hr/>
<xsl:if test="$hash">
<footer>
<p>
<small>Built with XSLT (<a>
<xsl:attribute name="href">https://git.pub0.org/heyainsleymae/curriculum-vitae/src/commit/<xsl:value-of select="$hash" /></xsl:attribute>view commit</a>)</small></p>
</footer>
</xsl:if>
</body>
</html>
</xsl:template>
</xsl:stylesheet>