mirror of
https://github.com/wasp-lang/open-saas.git
synced 2025-04-10 12:59:05 +02:00
update app_diff
This commit is contained in:
parent
6045c6133e
commit
4def591241
@ -0,0 +1,70 @@
|
||||
--- template/app/src/client/components/NavBar/NavBar.tsx
|
||||
+++ opensaas-sh/app/src/client/components/NavBar/NavBar.tsx
|
||||
@@ -32,6 +32,7 @@
|
||||
'shadow sticky bg-white bg-opacity-50 backdrop-blur-lg backdrop-filter dark:border dark:border-gray-100/10': !isLandingPage,
|
||||
})}
|
||||
>
|
||||
+ {isLandingPage && <Announcement />}
|
||||
<nav className='flex items-center justify-between p-6 lg:px-8' aria-label='Global'>
|
||||
<div className='flex items-center lg:flex-1'>
|
||||
<Link
|
||||
@@ -39,7 +40,7 @@
|
||||
className='flex items-center -m-1.5 p-1.5 text-gray-900 duration-300 ease-in-out hover:text-yellow-500'
|
||||
>
|
||||
<NavLogo />
|
||||
- {isLandingPage && <span className='ml-2 text-sm font-semibold leading-6 dark:text-white'>Your Saas</span>}
|
||||
+ {isLandingPage && <span className='ml-2 text-sm font-semibold leading-6 dark:text-white'>Open Saas</span>}
|
||||
</Link>
|
||||
</div>
|
||||
<div className='flex lg:hidden'>
|
||||
@@ -59,9 +60,9 @@
|
||||
</ul>
|
||||
{isUserLoading ? null : !user ? (
|
||||
<Link to='/login' className='text-sm font-semibold leading-6 ml-3'>
|
||||
- <div className='flex items-center duration-300 ease-in-out text-gray-900 hover:text-yellow-500 dark:text-white'>
|
||||
- Log in <BiLogIn size='1.1rem' className='ml-1 mt-[0.1rem]' />
|
||||
- </div>
|
||||
+ <div className='flex justify-end items-center duration-300 ease-in-out text-gray-900 hover:text-yellow-500 dark:text-white test-sm'>
|
||||
+ Try the demo App <BiLogIn size='1.1rem' className='ml-1' />
|
||||
+ </div>
|
||||
</Link>
|
||||
) : (
|
||||
<div className='ml-3'>
|
||||
@@ -94,7 +95,7 @@
|
||||
{isUserLoading ? null : !user ? (
|
||||
<Link to='/login'>
|
||||
<div className='flex justify-end items-center duration-300 ease-in-out text-gray-900 hover:text-yellow-500 dark:text-white'>
|
||||
- Log in <BiLogIn size='1.1rem' className='ml-1' />
|
||||
+ Try the Demo App{' '} <BiLogIn size='1.1rem' className='ml-1' />
|
||||
</div>
|
||||
</Link>
|
||||
) : (
|
||||
@@ -138,3 +139,27 @@
|
||||
}
|
||||
});
|
||||
}
|
||||
+
|
||||
+const ContestURL =
|
||||
+ 'https://docs.opensaas.sh/blog/';
|
||||
+
|
||||
+function Announcement() {
|
||||
+ return (
|
||||
+ <div className='flex justify-center items-center gap-3 p-3 w-full bg-gradient-to-r from-[#d946ef] to-[#fc0] font-semibold text-white text-center z-49'>
|
||||
+ <p onClick={() => window.open(ContestURL, '_blank')} className='hidden lg:block cursor-pointer hover:opacity-90 hover:drop-shadow'>🍪 THE MOST ANNOYING COOKIE BANNER EVER HACKATHON 🤬</p>
|
||||
+ <div className='hidden lg:block self-stretch w-0.5 bg-white'></div>
|
||||
+ <div
|
||||
+ onClick={() => window.open(ContestURL, '_blank')}
|
||||
+ className='hidden lg:block cursor-pointer rounded-full bg-neutral-700 px-2.5 py-1 text-xs hover:bg-neutral-600 tracking-wider'
|
||||
+ >
|
||||
+ Enter here and win prizes! →
|
||||
+ </div>
|
||||
+ <div
|
||||
+ onClick={() => window.open(ContestURL, '_blank')}
|
||||
+ className='lg:hidden cursor-pointer rounded-full bg-neutral-700 px-2.5 py-1 text-xs hover:bg-neutral-600 tracking-wider'
|
||||
+ >
|
||||
+ 🍪 The Most Annoying Cookie Banner Contest! 🤬 →
|
||||
+ </div>
|
||||
+ </div>
|
||||
+ );
|
||||
+}
|
||||
\ No newline at end of file
|
@ -1,88 +0,0 @@
|
||||
--- template/app/src/landing-page/components/Header.tsx
|
||||
+++ opensaas-sh/app/src/landing-page/components/Header.tsx
|
||||
@@ -1,4 +1,4 @@
|
||||
-import { useState } from 'react';
|
||||
+import { useState, useEffect } from 'react';
|
||||
import { HiBars3 } from 'react-icons/hi2';
|
||||
import { BiLogIn } from 'react-icons/bi';
|
||||
import { AiFillCloseCircle } from 'react-icons/ai';
|
||||
@@ -20,18 +20,19 @@
|
||||
|
||||
const { data: user, isLoading: isUserLoading } = useAuth();
|
||||
|
||||
- const NavLogo = () => <img className='h-8 w-8' src={logo} alt='Your SaaS App' />;
|
||||
+ const NavLogo = () => <img className='h-8 w-8' src={logo} alt='Open SaaS App' />;
|
||||
|
||||
return (
|
||||
<header className='absolute inset-x-0 top-0 z-50 dark:bg-boxdark-2'>
|
||||
+ <Announcement />
|
||||
<nav className='flex items-center justify-between p-6 lg:px-8' aria-label='Global'>
|
||||
<div className='flex items-center lg:flex-1'>
|
||||
<a
|
||||
href='/'
|
||||
- className='flex items-center -m-1.5 p-1.5 text-gray-900 duration-300 ease-in-out hover:text-yellow-500'
|
||||
+ className='flex items-center -m-1.5 p-1.5 text-gray-900 duration-300 ease-in-out hover:text-yellow-500 dark:text-white'
|
||||
>
|
||||
<NavLogo />
|
||||
- <span className='ml-2 text-sm font-semibold leading-6 dark:text-white'>Your Saas</span>
|
||||
+ <span className='ml-2 text-sm font-semibold leading-6 dark:text-white'>Open Saas</span>
|
||||
</a>
|
||||
</div>
|
||||
<div className='flex lg:hidden'>
|
||||
@@ -57,14 +58,14 @@
|
||||
</div>
|
||||
<div className='hidden lg:flex lg:flex-1 lg:justify-end lg:align-end'>
|
||||
{/* <!-- Dark Mode Toggler --> */}
|
||||
- <div className='flex items-center gap-3 2xsm:gap-7'>
|
||||
+ <div className='flex items-center gap-3 2xsm:gap-7 text-sm font-semibold leading-6'>
|
||||
<ul className='flex justify-center items-center gap-2 2xsm:gap-4'>
|
||||
<DarkModeSwitcher />
|
||||
</ul>
|
||||
{isUserLoading ? null : !user ? (
|
||||
<Link to='/login'>
|
||||
- <div className='flex justify-end items-center duration-300 ease-in-out text-gray-900 hover:text-yellow-500 dark:text-white'>
|
||||
- Log in <BiLogIn size='1.1rem' className='ml-1' />
|
||||
+ <div className='flex justify-end items-center duration-300 ease-in-out text-gray-900 hover:text-yellow-500 dark:text-white test-sm'>
|
||||
+ Try the demo App <BiLogIn size='1.1rem' className='ml-1' />
|
||||
</div>
|
||||
</Link>
|
||||
) : (
|
||||
@@ -107,8 +108,8 @@
|
||||
<div className='py-6'>
|
||||
{isUserLoading ? null : !user ? (
|
||||
<Link to='/login'>
|
||||
- <div className='flex justify-start items-center duration-300 ease-in-out text-gray-900 hover:text-yellow-500 dark:text-white'>
|
||||
- Log in <BiLogIn size='1.1rem' className='ml-1' />
|
||||
+ <div className='flex justify-end items-center duration-300 ease-in-out text-gray-900 hover:text-yellow-500 dark:text-white'>
|
||||
+ Try the Demo App{' '} <BiLogIn size='1.1rem' className='ml-1' />
|
||||
</div>
|
||||
</Link>
|
||||
) : (
|
||||
@@ -125,3 +126,27 @@
|
||||
</header>
|
||||
)
|
||||
}
|
||||
+
|
||||
+const ContestURL =
|
||||
+ 'https://docs.opensaas.sh/blog/';
|
||||
+
|
||||
+function Announcement() {
|
||||
+ return (
|
||||
+ <div className='flex justify-center items-center gap-3 p-3 w-full bg-gradient-to-r from-[#d946ef] to-[#fc0] font-semibold text-white text-center z-49'>
|
||||
+ <p onClick={() => window.open(ContestURL, '_blank')} className='hidden lg:block cursor-pointer hover:opacity-90 hover:drop-shadow'>🍪 THE MOST ANNOYING COOKIE BANNER EVER HACKATHON 🤬</p>
|
||||
+ <div className='hidden lg:block self-stretch w-0.5 bg-white'></div>
|
||||
+ <div
|
||||
+ onClick={() => window.open(ContestURL, '_blank')}
|
||||
+ className='hidden lg:block cursor-pointer rounded-full bg-neutral-700 px-2.5 py-1 text-xs hover:bg-neutral-600 tracking-wider'
|
||||
+ >
|
||||
+ Enter here and win prizes! →
|
||||
+ </div>
|
||||
+ <div
|
||||
+ onClick={() => window.open(ContestURL, '_blank')}
|
||||
+ className='lg:hidden cursor-pointer rounded-full bg-neutral-700 px-2.5 py-1 text-xs hover:bg-neutral-600 tracking-wider'
|
||||
+ >
|
||||
+ 🍪 The Most Annoying Cookie Banner Contest! 🤬 →
|
||||
+ </div>
|
||||
+ </div>
|
||||
+ );
|
||||
+}
|
@ -7,9 +7,9 @@
|
||||
-import { routes } from 'wasp/client/router';
|
||||
+import { DocsUrl, BlogUrl, GithubUrl } from '../shared/common';
|
||||
|
||||
export const navigation = [
|
||||
export const landingPageNavigationItems = [
|
||||
{ name: 'Features', href: '#features' },
|
||||
- { name: 'Pricing', href: routes.PricingPageRoute.build() },
|
||||
- { name: 'Pricing', to: routes.PricingPageRoute.to },
|
||||
{ name: 'Documentation', href: DocsUrl },
|
||||
{ name: 'Blog', href: BlogUrl },
|
||||
];
|
||||
|
Loading…
x
Reference in New Issue
Block a user