Skip to content

Commit

Permalink
Merge pull request #63 from RieLCho/master
Browse files Browse the repository at this point in the history
Enable horizontal centering
  • Loading branch information
050644zf authored Oct 11, 2024
2 parents 273c141 + 9409d27 commit ab25fd5
Showing 1 changed file with 18 additions and 7 deletions.
25 changes: 18 additions & 7 deletions reader/src/ASTRv2/content/img.vue
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
<template>
<n-image
:class="{
images: imgtype == 'images' || bgMode == 'full',
backgrounds: imgtype == 'backgrounds' && bgMode == 'stripe',
}"
:src="getAvgUrl()"
/>
<div class="image-container">
<n-image
:class="{
images: imgtype == 'images' || bgMode == 'full',
backgrounds: imgtype == 'backgrounds' && bgMode == 'stripe',
}"
:src="getAvgUrl()"
/>
</div>
</template>

<script>
Expand Down Expand Up @@ -39,6 +41,15 @@ export default {
</script>

<style>
.image-container {
text-align: center;
}
.image-container n-image {
display: block;
margin: 0 auto;
}
.line .images img {
max-width: 500px;
max-height: 300px;
Expand Down

0 comments on commit ab25fd5

Please sign in to comment.