link width & ionicons version pin

This commit is contained in:
cupcakearmy 2021-02-10 11:35:35 +01:00
parent 480bfb4e4a
commit 967019a2bd
No known key found for this signature in database
GPG Key ID: D28129AE5654D9D9
2 changed files with 25 additions and 15 deletions

View File

@ -4,6 +4,25 @@
export let project export let project
</script> </script>
<section>
<a href={project.link} target="_blank" rel="noopener">
<h2>{project.title}</h2>
</a>
<div>
<b>{project.description}</b>
<b class="date">{dj(project.date * 1000).format('MMM YY')}</b>
</div>
<p>
{@html project.content}
</p>
<ion-icon name="link-outline" />
<a class="link" rel="noopener noreferrer" target="_blank" href={project.link}
>{project.link.replace(/https?:\/\//, '')}</a
>
</section>
<style> <style>
h2 { h2 {
font-size: 2em; font-size: 2em;
@ -28,23 +47,14 @@
font-family: monospace; font-family: monospace;
} }
a.link {
display: block;
overflow: auto;
}
@media (max-width: 30em) { @media (max-width: 30em) {
div { div {
flex-direction: column; flex-direction: column;
} }
} }
</style> </style>
<section>
<a href={project.link} target="_blank" rel="noopener">
<h2>{project.title}</h2>
</a>
<div><b>{project.description}</b> <b class="date">{dj(project.date * 1000).format('MMM YY')}</b></div>
<p>
{@html project.content}
</p>
<ion-icon name="link-outline" />
<a rel="noopener noreferrer" target="_blank" href={project.link}>{project.link.replace(/https?:\/\//, '')}</a>
</section>

View File

@ -32,7 +32,7 @@
initialise the router --> initialise the router -->
%sapper.scripts% %sapper.scripts%
<script src="https://unpkg.com/ionicons@5/dist/ionicons.js"></script> <script src="https://unpkg.com/ionicons@5.4.0/dist/ionicons.js"></script>
<script type="text/javascript"> <script type="text/javascript">
var _paq = (window._paq = window._paq || []) var _paq = (window._paq = window._paq || [])