-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #58 from ric-v/main
UI Improvements and footer actions added
- Loading branch information
Showing
14 changed files
with
65 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
import Link from "next/link"; | ||
import ButtonGroup from "./ui-elements/ButtonGroup"; | ||
import Label from "./ui-elements/Label"; | ||
|
||
type Props = { | ||
hidden: string, | ||
|
@@ -16,7 +17,7 @@ const Footer = ({ hidden }: Props) => { | |
* @param {string} text | ||
* @param {string} link | ||
*/ | ||
const footerNav = (text: string, link: string, position: 'right' | 'middle' | 'left') => { | ||
const footerNav = (text: string, link: string, position: 'right' | 'middle' | 'left', _action?: () => void) => { | ||
if (link === hidden) { | ||
return null; | ||
} | ||
|
@@ -25,7 +26,7 @@ const Footer = ({ hidden }: Props) => { | |
<ButtonGroup position={position} toLayout='grid' layout={"grid"} setLayout={() => { }} > | ||
<Link passHref={true} href={link} as={link}> | ||
<a target={link.startsWith('http') ? '_blank' : '_self'}> | ||
<button className="text-white p-2"> | ||
<button className="text-white p-2" onClick={_action}> | ||
{text} | ||
</button> | ||
</a> | ||
|
@@ -35,20 +36,46 @@ const Footer = ({ hidden }: Props) => { | |
} | ||
|
||
return ( | ||
<div className='flex flex-col justify-center text-center mt-10 mb-5 bg-slate-900'> | ||
<div className='flex flex-col justify-center text-center mt-10 pb-5 bg-slate-900 border-t border-dashed border-gray-600'> | ||
<div className="flex flex-row justify-center"> | ||
<div className='grid grid-cols-2 md:grid-cols-2 text-center p-5'> | ||
<div className='grid grid-cols-2 md:grid-cols-4 text-center p-5'> | ||
{footerNav('the time is 🕟', '/', 'left')} | ||
{footerNav('the time was? ⌚', '/TimeWas', 'left')} | ||
{footerNav('Suggestions 🤔', '', 'middle', () => window.open('mailto:[email protected]?subject=Issue Report on and-the-time-is.web&body=Please describe the issue you are facing. Add the page on which the issue occured and screenshots if available.'))} | ||
{footerNav('Report bug 🪲', 'https://github.com/dev-asterix/and-the-time-is.web/issues/new?assignees=&labels=&template=bug_report.md&title=', 'middle')} | ||
{footerNav('make it better 🚀', 'https://github.com/dev-asterix/and-the-time-is', 'right')} | ||
</div> | ||
</div> | ||
<div className='text-red-800 font-semibold text-sm lg:text-md'> | ||
*Disclaimer: This is a demo app. Timezones and timestamps displayed here are not accurate yet. This is still work in progress. | ||
<div className='text-red-700 font-semibold text-sm lg:text-md mt-5'> | ||
*Disclaimer: Data inaccuracies are expected. | ||
</div> | ||
<div className='text-teal-500 font-bold'> | ||
source: <a href="https://en.wikipedia.org/wiki/List_of_tz_database_time_zones">Wikipedia tz database</a> | ||
</div> | ||
{/* <> | ||
<Label text='About' key={'about'} classes={'pb-2'} /> | ||
<div className='text-center md:text-left text-gray-400 | ||
md:border-l md:shadow-[-40px_0px_40px_-20px_rgba(0,0,0,0.33)] border-dashed border-slate-500 pl-2'> | ||
<p className='font-nova-flat'> | ||
<span className='text-teal-300'>'And the time is' </span>app is for those who wants to track current timestamps across the globe. | ||
Search for the timezones to keep track of and pin them to the dashboard for easy access. | ||
</p> | ||
<br /> | ||
<p className='font-nova-flat'> | ||
<span className='text-teal-300'>'And the time was'</span> helps you to track what the time was at a specific timezone compared to your location. | ||
It comes with a time picker to set the time you want to track across all selected timezones. | ||
</p> | ||
<br /> | ||
<p className='font-nova-flat'> | ||
This is a free and open source project under GPL-3 copyleft license. You can find the source code on <a className='text-teal-300' href='https://github.com/dev-asterix/and-the-time-is.web' target={'_blank'} rel="noreferrer" >Github</a>. | ||
</p> | ||
<div className='text-teal-500 font-bold'> | ||
source: <a href="https://en.wikipedia.org/wiki/List_of_tz_database_time_zones">Wikipedia tz database</a> | ||
</div> | ||
<br /> | ||
<p className='font-nova-flat'>Code. Share. Prosper.</p> | ||
</div> | ||
</> */} | ||
</div> | ||
) | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
da114c1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
and-the-time-is – ./
and-the-time-is-git-main-asterix-dev.vercel.app
andthetimeis.vercel.app
thetimeis.vercel.app
and-the-time-is-asterix-dev.vercel.app