Skip to content

Fixed Footer Alignment issue#35

Open
MaitreyeeBudhale wants to merge 1 commit intoDjedAlliance:mainfrom
MaitreyeeBudhale:footer-alignment-branch
Open

Fixed Footer Alignment issue#35
MaitreyeeBudhale wants to merge 1 commit intoDjedAlliance:mainfrom
MaitreyeeBudhale:footer-alignment-branch

Conversation

@MaitreyeeBudhale
Copy link

@MaitreyeeBudhale MaitreyeeBudhale commented Feb 26, 2026

Addressed Issues:

Made changes in the footer component
Fixes #32

Checklist

  • My PR addresses a single issue, fixes a single bug or makes a single improvement.
  • My code follows the project's code style and conventions.
  • If applicable, I have made corresponding changes or additions to the documentation.
  • If applicable, I have made corresponding changes or additions to tests.
  • My changes generate no new warnings or errors.
  • I have joined the Stability Nexus's Discord server and I will share a link to this PR with the project maintainers there.
  • I have read the Contribution Guidelines.
  • Once I submit my PR, CodeRabbit AI will automatically review it and I will address CodeRabbit's comments.

⚠️ AI Notice - Important!

We encourage contributors to use AI tools responsibly when creating Pull Requests. While AI can be a valuable aid, it is essential to ensure that your contributions meet the task requirements, build successfully, include relevant tests, and pass all linters. Submissions that do not meet these standards may be closed without warning to maintain the quality and integrity of the project. Please take the time to understand the changes you are proposing and their impact.

Summary by CodeRabbit

  • Style
    • Reorganized footer layout from multi-column horizontal arrangement to a vertically stacked structure. Logo and branding now appear at the top, followed by social links, with copyright information positioned below.

@coderabbitai
Copy link

coderabbitai bot commented Feb 26, 2026

📝 Walkthrough

Walkthrough

The Footer component was restructured from a horizontal multi-column layout to a compact vertical arrangement. The layout now features a top row containing the logo and "Djed Alliance" text, a bottom row with social links, and copyright text positioned below. Responsive flex directions, height constraints, and padding were updated accordingly.

Changes

Cohort / File(s) Summary
Footer Component Restructuring
src/components/pages/footer/Footer.tsx
Reorganized JSX structure from horizontal multi-column to vertical two-row layout. Updated flex direction classes for responsiveness. Added explicit height constraints (h-80px) and padding (p-2). Wrapped social links in anchor elements. Repositioned copyright text below main sections.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related issues

  • Issue #31: Directly addressed by the footer restructuring changes that fix alignment and spacing issues through the JSX layout reorganization and responsive flex class updates.

Poem

🐰 A footer once splayed side to side,
Now stacks vertically with vertical pride!
Two rows of harmony, spacing so neat,
With social links dancing to rhythm's sweet beat!
The Djed Alliance stands tall and aligned. ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title 'Fixed Footer Alignment issue' directly and clearly summarizes the main change in the PR, which involves reworking the footer layout to address alignment issues as described in both the summary and linked issue #32.
Linked Issues check ✅ Passed The code changes address all primary coding objectives from issue #32: reorganized layout with improved spacing, fixed alignment of text/icons, reduced footer height, added responsive structure with flex directions, and maintained styling for social icons.
Out of Scope Changes check ✅ Passed All changes in Footer.tsx are directly related to the footer alignment objectives from issue #32; no unrelated modifications or out-of-scope alterations were introduced.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@src/components/pages/footer/Footer.tsx`:
- Line 8: The footer's root element (<footer> in the Footer component) currently
uses the Tailwind class 'm-2' which adds outer margins and prevents full-width
rendering; remove 'm-2' (and optionally add 'w-full' if not already present)
from the <footer> element's className so it spans the full width while keeping
existing padding and height (e.g., update the <footer className='m-2 p-2
h-80px'> usage in Footer.tsx to remove 'm-2' and ensure 'p-2 h-80px' (and
'w-full' if desired)).
- Line 8: The footer component in Footer.tsx uses non-standard Tailwind classes
(h-80px, h-40px, h-16px); update those className values to use Tailwind
arbitrary value syntax (h-[80px], h-[40px], h-[16px]) wherever they appear
(e.g., the <footer> element and any child elements with those height classes) so
the styles apply without custom tailwind.config changes.
- Line 9: In Footer.tsx replace all incorrect Tailwind `align-middle` usages on
flex containers with `items-center` to properly center children on the
cross-axis; update the className on the main wrapper div (the element with
className 'flex lg:flex-col flex-col lg:justify-evenly align-middle
sm:justify-center md:justify-center') and the other Footer component divs
referenced in the review (lines noted) so they use `items-center` instead of
`align-middle`.

ℹ️ Review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7da6246 and 228fbeb.

📒 Files selected for processing (1)
  • src/components/pages/footer/Footer.tsx

<a href="https://discord.com/invite/5TWZwGXXym" target="_blank" rel="noreferrer" aria-label="Join Djed Alliance on Discord"><img className="socialImage mx-2 cursor-pointer" src={Discord} alt="Discord" /></a>
<a href="https://github.com/DjedAlliance" target="_blank" rel="noreferrer" aria-label="Djed Alliance GitHub"><img className="socialImage mx-2 cursor-pointer" src={GitHub} alt="GitHub" /></a>
<a href="https://twitter.com/DjedAlliance" target="_blank" rel="noreferrer" aria-label="Follow Djed Alliance on X (Twitter)"><img className="socialImage mx-2 cursor-pointer" src={Twitter} alt="X (Twitter)" /></a>
<footer className='m-2 p-2 h-80px'>
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Remove root margin to meet the full-width footer requirement.

Line [8] uses m-2, which creates side gaps and conflicts with the “footer spans full width” objective from issue #32.

Proposed fix
-		<footer className='m-2 p-2 h-80px'>
+		<footer className='w-full px-2 py-2'>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<footer className='m-2 p-2 h-80px'>
<footer className='w-full px-2 py-2'>
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/components/pages/footer/Footer.tsx` at line 8, The footer's root element
(<footer> in the Footer component) currently uses the Tailwind class 'm-2' which
adds outer margins and prevents full-width rendering; remove 'm-2' (and
optionally add 'w-full' if not already present) from the <footer> element's
className so it spans the full width while keeping existing padding and height
(e.g., update the <footer className='m-2 p-2 h-80px'> usage in Footer.tsx to
remove 'm-2' and ensure 'p-2 h-80px' (and 'w-full' if desired)).

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "Checking potentially invalid Tailwind classes in Footer:"
rg -n "h-80px|h-40px|h-16px" src/components/pages/footer/Footer.tsx || echo "File not found or no matches"

echo
echo "Locating Tailwind config files:"
fd -HI 'tailwind\.config\.(js|cjs|mjs|ts)$' . || echo "No config found"

echo
echo "Searching for config patterns:"
for f in $(fd -HI 'tailwind\.config\.(js|cjs|mjs|ts)$' . 2>/dev/null || true); do
  echo "---- $f ----"
  cat "$f" || true
done

Repository: DjedAlliance/DjedAlliance.github.io

Length of output: 1572


Replace non-standard Tailwind height classes with arbitrary value syntax.

The classes h-80px, h-40px, and h-16px are not standard Tailwind utilities and are not defined in your tailwind.config.cjs. Without custom configuration, these classes won't apply. Use Tailwind's arbitrary value syntax instead: h-[80px], h-[40px], h-[16px].

Suggested fix
-		<footer className='m-2 p-2 h-80px'>
+		<footer className='m-2 p-2 h-[80px]'>

-				<div className='flex flex-col md:flex-row md:justify-evenly h-80px p-2'>
+				<div className='flex flex-col md:flex-row md:justify-evenly h-[80px] p-2'>

-					<div className='flex flex-row justify-center align-middle mt-1 mb-1 md:mt-4 md:mb-4 h-40px'>
+					<div className='flex flex-row justify-center align-middle mt-1 mb-1 md:mt-4 md:mb-4 h-[40px]'>

-					<div className='flex flex-row mt-1 mb-1 md:mt-4 md:mt-4 justify-center align-middle h-40px'>
+					<div className='flex flex-row mt-1 mb-1 md:mt-4 md:mt-4 justify-center align-middle h-[40px]'>

-						<a className='h-16px flex flex-col justify-center align-middle' ...
+						<a className='h-[16px] flex flex-col justify-center align-middle' ...

Affects lines 8, 10, 11, 15, 16–18.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/components/pages/footer/Footer.tsx` at line 8, The footer component in
Footer.tsx uses non-standard Tailwind classes (h-80px, h-40px, h-16px); update
those className values to use Tailwind arbitrary value syntax (h-[80px],
h-[40px], h-[16px]) wherever they appear (e.g., the <footer> element and any
child elements with those height classes) so the styles apply without custom
tailwind.config changes.

<a href="https://github.com/DjedAlliance" target="_blank" rel="noreferrer" aria-label="Djed Alliance GitHub"><img className="socialImage mx-2 cursor-pointer" src={GitHub} alt="GitHub" /></a>
<a href="https://twitter.com/DjedAlliance" target="_blank" rel="noreferrer" aria-label="Follow Djed Alliance on X (Twitter)"><img className="socialImage mx-2 cursor-pointer" src={Twitter} alt="X (Twitter)" /></a>
<footer className='m-2 p-2 h-80px'>
<div className='flex lg:flex-col flex-col lg:justify-evenly align-middle sm:justify-center md:justify-center'>
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🌐 Web query:

Tailwind CSS align-middle vs items-center flex container alignment

💡 Result:

  • align-middle (Tailwind) → sets vertical-align: middle; and only affects inline / inline-block / table-cell elements (e.g., aligning an icon within a line of text). It does not align flex items. [1], [2]
  • items-center (Tailwind) → sets align-items: center; on a flex (or grid) container, centering its children on the cross axis (vertical in flex-row, horizontal in flex-col). [3], [4]

Typical flex centering

<div class="flex items-center justify-center h-32">
  <div>Centered</div>
</div>

items-center = cross-axis centering; justify-center = main-axis centering (per flexbox rules). [4]

When you might use align-middle

<p class="text-lg">
  Text <img class="inline-block align-middle" src="..." alt="" /> icon
</p>

This aligns the inline image within the text line, not within a flex container. [1], [2]

Sources: Tailwind vertical-align docs [1], MDN vertical-align applicability [2], Tailwind align-items / items-center mapping [3], MDN flex alignment overview [4].


🏁 Script executed:

fd Footer.tsx

Repository: DjedAlliance/DjedAlliance.github.io

Length of output: 117


🏁 Script executed:

cat -n src/components/pages/footer/Footer.tsx

Repository: DjedAlliance/DjedAlliance.github.io

Length of output: 2179


Replace align-middle with items-center for flex containers.

In Tailwind CSS, align-middle applies vertical-align: middle; which only affects inline and table-cell elements. For flex containers, use items-center to align items on the cross-axis. Lines 9, 11, 15, 16–18 incorrectly use align-middle in flex contexts.

Proposed fix
-			<div className='flex lg:flex-col flex-col lg:justify-evenly align-middle sm:justify-center md:justify-center'>
+			<div className='flex lg:flex-col flex-col lg:justify-evenly items-center sm:justify-center md:justify-center'>

-					<div className='flex flex-row justify-center align-middle mt-1 mb-1 md:mt-4 md:mb-4 h-40px'>
+					<div className='flex flex-row justify-center items-center mt-1 mb-1 md:mt-4 md:mb-4 h-40px'>

-					<div className='flex flex-row mt-1 mb-1 md:mt-4 md:mt-4 justify-center align-middle h-40px'>
+					<div className='flex flex-row mt-1 mb-1 md:mt-4 md:mt-4 justify-center items-center h-40px'>

-						<a className='h-16px flex flex-col justify-center align-middle' ...
+						<a className='h-16px flex flex-col justify-center items-center' ...
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/components/pages/footer/Footer.tsx` at line 9, In Footer.tsx replace all
incorrect Tailwind `align-middle` usages on flex containers with `items-center`
to properly center children on the cross-axis; update the className on the main
wrapper div (the element with className 'flex lg:flex-col flex-col
lg:justify-evenly align-middle sm:justify-center md:justify-center') and the
other Footer component divs referenced in the review (lines noted) so they use
`items-center` instead of `align-middle`.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant