Skip to content
This repository has been archived by the owner on Apr 21, 2024. It is now read-only.

feat: creating a footer #42

Merged
merged 31 commits into from
Oct 25, 2023
Merged
Show file tree
Hide file tree
Changes from 24 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
79ad5a7
feat: create footer
CBID2 Oct 17, 2023
7657538
feat: added code and logo
CBID2 Oct 17, 2023
5c5683e
feat: add width
CBID2 Oct 18, 2023
3e08bb4
Revert "feat: create footer"
CBID2 Oct 18, 2023
5485bd3
feat: add comments here
CBID2 Oct 18, 2023
42ad87d
feat: add export value
CBID2 Oct 18, 2023
1a64f93
feat: add CSS
CBID2 Oct 18, 2023
8bd02e3
feat: upload logo
CBID2 Oct 19, 2023
47737b8
feat: imported logo
CBID2 Oct 19, 2023
0a8825c
feat: add height and width to logo
CBID2 Oct 19, 2023
f2f404a
feat: add copyright information
CBID2 Oct 19, 2023
c17417f
Merge branch 'YurisCodingClub:main' into adding-a-footer
CBID2 Oct 20, 2023
f215aac
fix: revise import name
CBID2 Oct 20, 2023
60e56a7
fix: moved images
CBID2 Oct 20, 2023
3a4e9a5
fix: revise file path for import logo
CBID2 Oct 20, 2023
4e9b186
fix: revise file path for image import again
CBID2 Oct 20, 2023
3739d91
fix: revising the file path again
CBID2 Oct 20, 2023
418a74a
fix: made image a self-closing tag
CBID2 Oct 20, 2023
11f425c
fix: moved logo and renamed file path
CBID2 Oct 22, 2023
d127280
fix: revise file path
CBID2 Oct 22, 2023
18494d6
fix: moved logo.svg to a new folder
CBID2 Oct 22, 2023
c46ebfa
fix: replace CSS property
CBID2 Oct 22, 2023
929f806
fix: revise height property to auto
CBID2 Oct 22, 2023
5f78e4a
fix: add margin and text-align center
CBID2 Oct 22, 2023
d722626
fix: remove extra CSS and revise alt text
CBID2 Oct 23, 2023
c623715
feat: import footer to main page
CBID2 Oct 23, 2023
4011381
fix: omit alt text
CBID2 Oct 24, 2023
9bbda8e
fix: improved footer's CSS
CBID2 Oct 24, 2023
7acab80
fix: went with simple CSS
CBID2 Oct 25, 2023
a1d26a3
fix: remove space between the quotation marks near alt=
CBID2 Oct 25, 2023
5c82834
fix: add space between imports & function for readability
CBID2 Oct 25, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions pages/components/Footer.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import React from "react";
import Image from "next/image";
import logo from "../../stories/assets/logo.png";

const Footer = () => {
return (
<footer
style={{
width: "100%",
position: "fixed",
bottom: "0",
margin: "auto",
textAlign: "center",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't necessary to fulfill the AC πŸ‘‡πŸ½

  • No additional styling needed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noted

}}
>
<Image src={logo} alt="footer-logo" width={100} height="auto" />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Concerning accessibility, think of a better alt text for the logo, or if alt text is even needed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @YuriDevAT! :) I think it's best to keep the alt text so it can be read by screen readers.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right, alt text is for being read by screen reader users, but that does not necessarily mean you should add one. Especially when it comes to logos (which does not link to anything, yet), the alt text should be left empty like this alt="".
Read this article about alt text decision tree, it is really helpful to understand the need of alt text better https://www.w3.org/WAI/tutorials/images/decision-tree/

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A detailed alt text is typical and very good when it comes to images, I never saw it for logos, though. Logos are mostly used as links (like, Go To Homepage, or Go To Website when it is a logo which links to another companies website). But at the current state, the logo does not link anywhere, so no alt text needed (it will be a future issue, though, so keep your eyes open πŸ‘€ )

❗ But I like how detailed you are able to describe even a logo, this is a skill not many people have. Hopefully, you make good use of it in the future, when alt text is needed on descriptive images πŸ™ŒπŸ½

<p className="copyright">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this class in use? If not, then it can be deleted.

AccessibilityMentor 2023. All rights reserved.
</p>
</footer>
);
};

export default Footer;
Binary file added stories/assets/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading