Make Footer it's own component

This commit is contained in:
Korbs 2024-12-11 20:41:04 -05:00
parent 96b24bedbb
commit a8c2c5324a
3 changed files with 31 additions and 43 deletions

View file

@ -0,0 +1,23 @@
---
// Settings
import { SiteSettings, FeelbackConfig } from '@config'
import {version} from '../../../package.json'
---
<div class="footer">
<div class="footer-start">
<p>© {SiteSettings.OrgName}. All right reserved.</p>
</div>
<div class="footer-end">
{SiteSettings.WhiteLabel ?
<p>Built with <a href="#">ButterflyVu</a></p>
:
null
}
{SiteSettings.FooterVersion ?
<p style="opacity: 0.5;">v{version}</p>
:
null
}
</div>
</div>

View file

@ -1,7 +1,6 @@
---
// Settings
import { SiteSettings, FeelbackConfig } from '@config'
import {version} from '../../package.json'
import { FeelbackConfig } from '@config'
// Properties
const { frontmatter, Title, Feedback, Feelback } = Astro.props
@ -9,6 +8,7 @@ const { frontmatter, Title, Feedback, Feelback } = Astro.props
// Components
import Head from '@components/global/Head.astro'
import Header from '@components/global/Header.astro'
import Footer from '@components/global/Footer.astro'
import Sidebar from '@components/Sidebar.astro'
import FeelbackYesNo from "astro-feelback/components/FeelbackYesNo.astro"
import {Zorn} from "@minpluto/zorn"
@ -41,25 +41,9 @@ import "@styles/prism.css"
}
</div>
</article>
<Footer/>
<!-- Zorn is broken if a player is not already set -->
<Zorn is:raw PlayerName="zorn_null" Poster="#" Video="#"/>
<div class="footer">
<div class="footer-start">
<p>© {SiteSettings.OrgName}. All right reserved.</p>
</div>
<div class="footer-end">
{SiteSettings.WhiteLabel ?
<p>Built with <a href="#">ButterflyVu</a></p>
:
null
}
{SiteSettings.FooterVersion ?
<p style="opacity: 0.5;">v{version}</p>
:
null
}
</div>
</div>
</div>
<!-- Zorn is broken if a player is not already set -->

View file

@ -1,14 +1,11 @@
---
// Settings
import { SiteSettings } from '@config'
import {version} from '../../package.json'
// Properties
const { frontmatter } = Astro.props
// Components
import Head from '@components/global/Head.astro'
import Header from '@components/global/Header.astro'
import Footer from '@components/global/Footer.astro'
import FeelbackYesNo from "astro-feelback/components/FeelbackYesNo.astro";
// Styles
@ -26,8 +23,8 @@ import "@styles/feelback.css";
<h1>{frontmatter.Title}</h1>
<p>{frontmatter.Description}</p>
<div class="splash-action">
<a href={frontmatter.PrimaryLink} class="button">{frontmatter.PrimaryText}</a>
<a href={frontmatter.SecondaryLink} class="button-secondary">{frontmatter.SecondaryText}</a>
{frontmatter.PrimaryText ? <a href={frontmatter.PrimaryLink} class="button">{frontmatter.PrimaryText}</a> : null}
{frontmatter.SecondaryText ? <a href={frontmatter.SecondaryLink} class="button-secondary">{frontmatter.SecondaryText}</a> : null}
</div>
</div>
<img src={frontmatter.Banner}/>
@ -36,22 +33,6 @@ import "@styles/feelback.css";
<slot/>
</div>
</div>
<div class="footer">
<div class="footer-start">
<p>© {SiteSettings.OrgName}. All right reserved.</p>
</div>
<div class="footer-end">
{SiteSettings.WhiteLabel ?
<p>Built with <a href="#">ButterflyVu</a></p>
:
null
}
{SiteSettings.FooterVersion ?
<p style="opacity: 0.5;">v{version}</p>
:
null
}
</div>
</div>
<Footer/>
</div>
</html>