Update button title and make banner title optional
The button title on the main page has been changed to "Explore ScrewFast on GitHub". Also, the title for AnnouncementBanner is now optional, enabling use of the banner without a predefined title, increasing its reusability. The CSS styles have also been updated to accommodate these changes.
This commit is contained in:
parent
6edea738fa
commit
e95dd9987a
2 changed files with 5 additions and 4 deletions
|
@ -2,7 +2,7 @@
|
|||
const { title, btnId, btnTitle, url } = Astro.props;
|
||||
|
||||
interface Props {
|
||||
title: string;
|
||||
title?: string;
|
||||
btnId: string;
|
||||
btnTitle: string;
|
||||
url: string;
|
||||
|
@ -18,13 +18,15 @@ interface Props {
|
|||
>
|
||||
<div class="flex items-center justify-center">
|
||||
<div class="ml-auto">
|
||||
{title &&
|
||||
<p
|
||||
class="me-2 inline-block font-medium text-neutral-50 dark:text-neutral-700"
|
||||
>
|
||||
{title}
|
||||
</p>
|
||||
}
|
||||
<a
|
||||
class="group inline-flex items-center gap-x-2 rounded-full border-2 border-neutral-50 px-3 py-2 text-sm font-semibold text-neutral-50 transition duration-300 hover:border-neutral-100/70 hover:text-neutral-50/70 disabled:pointer-events-none disabled:opacity-50 dark:border-neutral-700 dark:text-neutral-700 dark:hover:border-neutral-700/70 dark:hover:text-neutral-800/70 dark:focus:outline-none"
|
||||
class="group inline-flex items-center gap-x-2 rounded-full border-2 border-neutral-50 backdrop-brightness-75 sm:backdrop-brightness-100 px-3 py-2 text-sm font-semibold text-neutral-50 transition duration-300 hover:border-neutral-100/70 hover:text-neutral-50/70 disabled:pointer-events-none disabled:opacity-50 dark:border-neutral-700 dark:text-neutral-700 dark:hover:border-neutral-700/70 dark:hover:text-neutral-800/70 dark:focus:outline-none"
|
||||
href={url}
|
||||
target="_blank"
|
||||
>
|
||||
|
|
|
@ -21,9 +21,8 @@ const avatarSrcs: Array<string> = [
|
|||
|
||||
<MainLayout>
|
||||
<AnnouncementBanner
|
||||
title="ScrewFast is Live"
|
||||
btnId="dismiss-button"
|
||||
btnTitle="Learn more"
|
||||
btnTitle="Explore ScrewFast on GitHub"
|
||||
url="https://github.com/mearashadowfax/ScrewFast"
|
||||
/>
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue