mirror of
https://github.com/ChenQihan666/MyBlog-Next.git
synced 2026-08-14 11:29:33 +08:00
Fix styling
This commit is contained in:
@@ -1,8 +1,5 @@
|
||||
---
|
||||
import socialIcons from "@assets/socialIcons";
|
||||
import { SOCIALS } from "src/config";
|
||||
import Hr from "./Hr.astro";
|
||||
import LinkButton from "./LinkButton.astro";
|
||||
import Socials from "./Socials.astro";
|
||||
|
||||
const currentYear = new Date().getFullYear();
|
||||
@@ -17,7 +14,7 @@ const { noMarginTop = false } = Astro.props;
|
||||
<footer class={`${noMarginTop ? "" : "mt-auto"}`}>
|
||||
<Hr noPadding />
|
||||
<div class="footer-wrapper">
|
||||
<Socials />
|
||||
<Socials centered />
|
||||
<div class="copyright-wrapper">
|
||||
<span>Copyright © {currentYear}</span>
|
||||
<span class="separator"> | </span>
|
||||
|
||||
@@ -2,10 +2,16 @@
|
||||
import { SOCIALS } from "src/config";
|
||||
import LinkButton from "./LinkButton.astro";
|
||||
import socialIcons from "@assets/socialIcons";
|
||||
|
||||
export interface Props {
|
||||
centered?: boolean;
|
||||
}
|
||||
|
||||
const { centered = false } = Astro.props;
|
||||
---
|
||||
|
||||
|
||||
<div class="social-icons">
|
||||
<div class={`social-icons ${centered ? "flex" : ""}`}>
|
||||
{
|
||||
SOCIALS.filter((social) => social.active).map((social) => (
|
||||
<LinkButton
|
||||
@@ -21,8 +27,7 @@ import socialIcons from "@assets/socialIcons";
|
||||
|
||||
<style>
|
||||
.social-icons {
|
||||
@apply flex flex-wrap justify-center gap-1;
|
||||
@apply mt-1 sm:mt-0 sm:ml-2 sm:space-x-1;
|
||||
@apply flex-wrap justify-center gap-1;
|
||||
}
|
||||
.link-button {
|
||||
@apply p-2 sm:p-1 hover:rotate-6;
|
||||
|
||||
@@ -47,7 +47,7 @@ const sortedPosts = getSortedPosts(posts);
|
||||
> for more info.
|
||||
</p>
|
||||
<div class="social-wrapper">
|
||||
<div class="whitespace-nowrap">Social Links:</div>
|
||||
<div class="social-links">Social Links:</div>
|
||||
<Socials />
|
||||
</div>
|
||||
</section>
|
||||
@@ -106,7 +106,7 @@ const sortedPosts = getSortedPosts(posts);
|
||||
<Footer />
|
||||
</Layout>
|
||||
|
||||
<style is:global>
|
||||
<style>
|
||||
/* ===== Hero Section ===== */
|
||||
#hero {
|
||||
@apply pt-8;
|
||||
@@ -126,6 +126,9 @@ const sortedPosts = getSortedPosts(posts);
|
||||
.social-wrapper {
|
||||
@apply flex flex-col sm:flex-row sm:items-center mt-4 mb-6;
|
||||
}
|
||||
.social-links {
|
||||
@apply whitespace-nowrap mr-2 sm:mb-0 mb-1;
|
||||
}
|
||||
|
||||
/* ===== Featured & Recent Posts Sections ===== */
|
||||
#featured,
|
||||
|
||||
Reference in New Issue
Block a user