fix: tag-ak ongi jartzen ditu
This commit is contained in:
1 parent
8ac7674e7a
commit
24b1b5b2ec
5 files changed
+30
-23
No files matched your search
@@ -1,14 +1,13 @@
|
||||
---
|
||||
interface Props {
|
||||
tags: string[];
|
||||
all?: boolean;
|
||||
centered?: boolean;
|
||||
}
|
||||
|
||||
const { tags, all } = Astro.props;
|
||||
const { tags, centered } = Astro.props;
|
||||
---
|
||||
|
||||
{all && <h3 class="tag-title">Ikusi postak etiketaren arabera</h3>}
|
||||
<div class="tags">
|
||||
<div class={`${centered ? "centered" : ""}`}>
|
||||
{
|
||||
tags &&
|
||||
tags.map((tag) => (
|
||||
@@ -21,3 +20,26 @@ const { tags, all } = Astro.props;
|
||||
))
|
||||
}
|
||||
</div>
|
||||
|
||||
<style>
|
||||
div {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 1em;
|
||||
}
|
||||
|
||||
.centered {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.tag {
|
||||
display: inline-block;
|
||||
color: var(--black);
|
||||
font-size: 0.8rem;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
font-weight: bold;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
+1
-1
@@ -22,7 +22,7 @@ const tags = getTags(posts);
|
||||
<main>
|
||||
404: Ez da orria aurkitu
|
||||
|
||||
<Tags tags={tags} all />
|
||||
<Tags tags={tags} centered />
|
||||
</main>
|
||||
<Footer />
|
||||
<ColorScript /></Container
|
||||
|
||||
@@ -35,7 +35,8 @@ const tags = getTags(posts);
|
||||
<br />
|
||||
|
||||
<Container>
|
||||
<Tags tags={tags} all />
|
||||
<h3 class="tag-title">Ikusi postak etiketaren arabera</h3>
|
||||
<Tags tags={tags} centered />
|
||||
</Container>
|
||||
</main>
|
||||
<Container>
|
||||
|
||||
@@ -31,7 +31,7 @@ const tags = getTags(posts);
|
||||
</Container>
|
||||
<main>
|
||||
<content>
|
||||
<Tags tags={tags} />
|
||||
<Tags tags={tags} centered />
|
||||
<PostGrid posts={posts} />
|
||||
</content>
|
||||
</main>
|
||||
|
||||
@@ -168,22 +168,6 @@ ul.tags-list {
|
||||
font-size: 1.3em;
|
||||
}
|
||||
|
||||
.tags {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
}
|
||||
.tag {
|
||||
display: inline-block;
|
||||
margin-right: 20px;
|
||||
color: var(--black);
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
.tag:hover {
|
||||
cursor: pointer;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
textarea {
|
||||
width: 100%;
|
||||
font-size: 16px;
|
||||
|
||||
Reference in new issue
Block a user