(notes) share notes

This commit is contained in:
Julien Calixte
2021-04-25 17:04:51 +02:00
parent 2550ec83f7
commit 3f2af0ea75
4 changed files with 68 additions and 22 deletions

View File

@@ -12,6 +12,16 @@
{{ displayedTitle }}
</a>
</div>
<div class="share">
<router-link
:to="{
name: 'ShareNotes',
params: { user: user, repo: repo, note: sha }
}"
>
<img src="@/assets/icons/share.svg" alt="share" />
</router-link>
</div>
<section class="note-content" v-html="content"></section>
</div>
</template>
@@ -27,6 +37,8 @@ import { useImages } from '@/hooks/useImages.hook'
export default defineComponent({
name: 'StackedNote',
props: {
user: { type: String, required: true },
repo: { type: String, required: true },
index: { type: Number, required: true },
title: { type: String, required: true },
sha: { type: String, required: true }
@@ -99,6 +111,13 @@ $border-color: rgba(18, 19, 58, 0.2);
}
}
.share {
float: right;
img {
vertical-align: bottom;
}
}
@media screen and (max-width: 768px) {
.stacked-note {
padding: 0 1.5rem;