Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated Mission and Signup Section Interface #398

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

royvivi29
Copy link
Contributor

@royvivi29 royvivi29 commented Oct 25, 2024

Issues Identification

Closes: #(393)

Description

Redesigned the Mission and Signup sections to improve user experience and visual appeal. Enhanced layout, updated interface elements, and optimized accessibility to create a more engaging and user-friendly experience for visitors.

Checklist

Please check the boxes that apply

  • [ 👍] My code follows the style guidelines of this project
  • [👍 ] I have performed a self-review of my own code
  • [👍 ] I have commented my code, particularly in hard-to-understand areas
  • [ 👍] My changes generate no new warnings
  • [👍 ] My changes do not break the current system and pass all existing test cases
  • [ 👍] I have added tests that prove my fix is effective or that my feature works
  • [👍 ] New and existing unit tests pass locally with my changes
  • [ 👍] Any dependent changes have been merged and published in downstream modules

Screenshots

Screenshot 2024-10-25 080822
Screenshot 2024-10-25 080836

Summary by CodeRabbit

  • New Features

    • Introduced "Our Mission" and "Core Values" sections to highlight organizational goals and principles.
    • Added a "Sign Up" section for user registration.
    • Updated FAQ section for improved clarity and structure.
    • Enhanced footer with newsletter subscription and social media links.
  • Style

    • Improved styling for various components, including new classes for forms and buttons.
    • Enhanced layout for eco tips and user interaction elements.
    • Adjusted media queries for better responsiveness across devices.

Copy link
Contributor

coderabbitai bot commented Oct 25, 2024

Walkthrough

The changes in this pull request involve substantial structural and content updates to the index.html and styles.css files for a waste management website. New sections such as "Our Mission," "Core Values," and "Sign Up" have been added to the HTML, along with a reformatted FAQ section for clarity. The CSS has been enhanced with new styles and classes to improve the layout and presentation of various components, ensuring a better user experience and responsive design.

Changes

File Change Summary
index.html Added new sections: "Our Mission," "Core Values," and "Sign Up"; reformatted FAQ section; updated footer.
styles.css Added and updated styles for .mission-item, .signup, form classes, .eco-tips-container, and .feedback.

Possibly related PRs

Suggested labels

gssoc-ext, hacktoberfest, level2, hacktoberfest-accepted

Suggested reviewers

  • GarimaSingh0109

Poem

In the garden of waste, we plant a new dream,
With values and mission, we craft a bright scheme.
Sign up for the journey, let’s make a new start,
Together we’ll flourish, each playing a part! 🌱✨
FAQs now clearer, our message is true,
For a greener tomorrow, let’s all join the crew!


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

netlify bot commented Oct 25, 2024

Deploy Preview for manageyourwaste failed. Why did it fail? →

Name Link
🔨 Latest commit 1e3b2d2
🔍 Latest deploy log https://app.netlify.com/sites/manageyourwaste/deploys/671b0702859a160008fd2cca

Copy link
Contributor

@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

🧹 Outside diff range and nitpick comments (2)
index.html (2)

Line range hint 31-40: Remove duplicate navigation section.

The navigation section is duplicated, which could cause confusion and potential rendering issues.

Remove the duplicate navigation section:

- <nav>
-   <div class="btn-nav">
-     <button class="button"> <a href="#upload">Upload</a></button>
-     <button class="button"><a href="#features">Features</a></button>
-     <button class="button"><a href="#feedback">Feedback</a></button>
-     <button class="button"><a href="#about">About Me</a></button>
-     <button class="button"><a href="register.html">Sign up</a></button>
-     <button class="button"><a href="#footer">Contact</a></button>
-   </div>
- </nav>

Line range hint 381-426: Consolidate duplicate footer sections.

There are multiple footer sections with similar content. This should be consolidated into a single, well-structured footer.

  1. Remove the duplicate footer sections
  2. Combine the unique elements from each footer
  3. Maintain a single source of footer content
- <footer id="footer">
-   <!-- First footer content -->
- </footer>
- <!-- ... -->
- <footer id="footer">
-   <!-- Second footer content -->
- </footer>

+ <footer id="footer">
+   <h2>Stay Connected</h2>
+   <form id="newsletter-form" name="newsletter-form">
+     <input type="email" placeholder="Your Email" required />
+     <span id="newsletter-error-message" style="color: red;"></span>
+     <button type="submit">Subscribe</button>
+   </form>
+   
+   <div class="social-media">
+     <!-- Combined social media links -->
+   </div>
+   
+   <div class="community-message">
+     <!-- Single community message -->
+   </div>
+   
+   <div class="footer-links">
+     <!-- Combined footer links -->
+   </div>
+   
+   <p>&copy; 2024 Waste Management. All rights reserved.</p>
+ </footer>

Also applies to: 642-735

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Files that changed from the base of the PR and between 7880a0f and 1e3b2d2.

📒 Files selected for processing (2)
  • index.html (5 hunks)
  • styles.css (2 hunks)
🔇 Additional comments (1)
styles.css (1)

387-392: LGTM! Well-structured image styles for mission items.

The styles ensure responsive images with proper spacing and rounded corners, maintaining aspect ratio.

Comment on lines +314 to +338
<div class="signup">
<div class="container">
<div class="form_area">
<p class="title">SIGN UP</p>
<form action="">
<div class="form_group">
<label class="sub_title" for="name">Name</label>
<input placeholder="Enter your full name" class="form_style" type="text" id="name">
</div>
<div class="form_group">
<label class="sub_title" for="email">Email</label>
<input placeholder="Enter your email" id="email" class="form_style" type="email">
</div>
<div class="form_group">
<label class="sub_title" for="password">Password</label>
<input placeholder="Enter your password" id="password" class="form_style" type="password">
</div>
<div class="form_action">
<button class="btn">SIGN UP</button>
<p>Have an Account? <a class="link" href="">Login Here!</a></p>
</div>
</form>
</div>
</div>
</div>
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue

Enhance form accessibility and validation.

The sign-up form needs improvements in accessibility and validation:

  1. Missing form validation attributes
  2. Incomplete ARIA labels
  3. Improper input-label associations

Apply these improvements:

- <form action="">
+ <form action="/signup" method="POST" novalidate>
   <div class="form_group">
-    <label class="sub_title" for="name">Name</label>
-    <input placeholder="Enter your full name" class="form_style" type="text" id="name">
+    <label class="sub_title" for="signup-name">Name</label>
+    <input 
+      id="signup-name"
+      name="name"
+      placeholder="Enter your full name" 
+      class="form_style" 
+      type="text"
+      required
+      aria-required="true"
+      minlength="2"
+    >
   </div>
   <!-- Similar improvements for email and password fields -->

Committable suggestion was skipped due to low confidence.

Comment on lines +252 to +279
<!-- Mission Section -->
<div class="mission-container">
<h3>Our Mission</h3>
<div class="mission-box">
<div class="mission-item">
<img src="./assets/recycling-bin_532768.png" alt="Reduce Waste">
<h4>Reduce Waste</h4>
<p>Minimize waste generation through innovative technologies and education.</p>
</div>
<div class="mission-item">
<img src="./assets/aluminum_4381614.png" alt="Promote Recycling">
<h4>Promote Recycling</h4>
<p>Encourage responsible disposal and recycling practices in every community.</p>
</div>
<div class="mission-item">
<img src="./assets/solidarity_16825525.png" alt="Empower Communities">
<h4>Empower Communities</h4>
<p>Equip individuals with knowledge and tools for sustainable living.</p>
</div>
<div class="mission-item">
<img src="./assets/exterior-cleaning_17073146.png" alt="Build a Cleaner Future">
<h4>Build a Cleaner Future</h4>
<p>Protect the environment for future generations.</p>
</div>
</div>
</div>
</div>
</section>
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue

Improve semantic markup in Mission section.

The mission section needs better semantic structure and heading hierarchy.

Apply these semantic improvements:

- <div class="mission-container">
+ <section class="mission" aria-labelledby="mission-heading">
-   <h3>Our Mission</h3>
+   <h2 id="mission-heading">Our Mission</h2>
    <div class="mission-box">
-     <div class="mission-item">
+     <article class="mission-item">
        <!-- content -->
-     </div>
+     </article>
      <!-- Similar changes for other mission items -->
    </div>
- </div>
+ </section>

Committable suggestion was skipped due to low confidence.

Comment on lines +422 to +526
text-align: center;
margin-bottom: 25px;
}

.signup input {
margin: 10px 0;
padding: 10px;
border: 1px solid #ccc;
border-radius: 4px;
/* Form Group Styling */
.form_group {
margin-bottom: 20px;
}

.signup button {
background-color: #007b5f;
/* Label Styling */
.sub_title {
font-size: 1em;
color: #333;
margin-bottom: 5px;
display: block;
}

/* Input Styling */
.form_style {
width: 100%;
padding: 12px;
border: 1px solid #ddd;
border-radius: 5px;
transition: border-color 0.3s;
font-size: 1em;
}

.form_style:focus {
border-color: #007b5f;
outline: none;
box-shadow: 0 0 8px rgba(0, 123, 95, 0.2);
}

/* Button Styling */
.btn {
width: 100%;
padding: 12px;
font-size: 1em;
font-weight: bold;
color: white;
padding: 10px;
background-color: #007b5f;
border: none;
border-radius: 4px;
border-radius: 5px;
cursor: pointer;
transition: background-color 0.3s;
transition: background-color 0.3s, transform 0.1s;
}

.signup button:hover {
.btn:hover {
background-color: #005f46;
}

.btn:active {
transform: scale(0.98);
}

/* Link Styling */
.link {
color: #007b5f;
text-decoration: none;
font-weight: bold;
}

.link:hover {
text-decoration: underline;
}

/* Text under button */
.form_action p {
text-align: center;
font-size: 0.9em;
margin-top: 15px;
}

/* Responsive Styling */
@media (max-width: 500px) {
.signup {
padding: 20px;
max-width: 90%;
margin: 0 auto;
}

.signup .title {
font-size: 1.6em;
}

.btn, .form_style {
font-size: 0.95em;
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion

Enhance accessibility and maintainability of the signup form styles.

While the overall structure is good, consider the following improvements:

  1. Add focus styles for better accessibility:
 .link {
   color: #007b5f;
   text-decoration: none;
   font-weight: bold;
+  outline: none;
 }

+.link:focus {
+  outline: 2px solid #007b5f;
+  outline-offset: 2px;
+}
  1. Use CSS variables for consistent colors:
+:root {
+  --primary-color: #007b5f;
+  --primary-dark: #005f46;
+  --border-color: #ddd;
+}

 .form_style {
-  border: 1px solid #ddd;
+  border: 1px solid var(--border-color);
 }

 .form_style:focus {
-  border-color: #007b5f;
+  border-color: var(--primary-color);
 }

 .btn {
-  background-color: #007b5f;
+  background-color: var(--primary-color);
 }

 .btn:hover {
-  background-color: #005f46;
+  background-color: var(--primary-dark);
 }
  1. Add transition property to focus state for smooth animation:
 .form_style:focus {
   border-color: #007b5f;
   outline: none;
   box-shadow: 0 0 8px rgba(0, 123, 95, 0.2);
+  transition: all 0.3s ease;
 }
  1. Ensure sufficient color contrast for accessibility:
 .link {
-  color: #007b5f;
+  color: #006048;  /* Darker shade for better contrast */
 }
📝 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
/* Container Styling */
.signup {
background-color: #f9f9f9;
padding: 20px;
border-radius: 8px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
background-color: #ffffff;
padding: 30px;
border-radius: 10px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
max-width: 400px;
margin: 0 auto 30px;
margin: 0 auto;
font-family: Arial, sans-serif;
}
.signup form {
display: flex;
flex-direction: column;
/* Title Styling */
.signup .title {
font-size: 1.8em;
font-weight: 600;
color: #333;
text-align: center;
margin-bottom: 25px;
}
.signup input {
margin: 10px 0;
padding: 10px;
border: 1px solid #ccc;
border-radius: 4px;
/* Form Group Styling */
.form_group {
margin-bottom: 20px;
}
.signup button {
background-color: #007b5f;
/* Label Styling */
.sub_title {
font-size: 1em;
color: #333;
margin-bottom: 5px;
display: block;
}
/* Input Styling */
.form_style {
width: 100%;
padding: 12px;
border: 1px solid #ddd;
border-radius: 5px;
transition: border-color 0.3s;
font-size: 1em;
}
.form_style:focus {
border-color: #007b5f;
outline: none;
box-shadow: 0 0 8px rgba(0, 123, 95, 0.2);
}
/* Button Styling */
.btn {
width: 100%;
padding: 12px;
font-size: 1em;
font-weight: bold;
color: white;
padding: 10px;
background-color: #007b5f;
border: none;
border-radius: 4px;
border-radius: 5px;
cursor: pointer;
transition: background-color 0.3s;
transition: background-color 0.3s, transform 0.1s;
}
.signup button:hover {
.btn:hover {
background-color: #005f46;
}
.btn:active {
transform: scale(0.98);
}
/* Link Styling */
.link {
color: #007b5f;
text-decoration: none;
font-weight: bold;
}
.link:hover {
text-decoration: underline;
}
/* Text under button */
.form_action p {
text-align: center;
font-size: 0.9em;
margin-top: 15px;
}
/* Responsive Styling */
@media (max-width: 500px) {
.signup {
padding: 20px;
max-width: 90%;
margin: 0 auto;
}
.signup .title {
font-size: 1.6em;
}
.btn, .form_style {
font-size: 0.95em;
}
}
/* Container Styling */
:root {
--primary-color: #007b5f;
--primary-dark: #005f46;
--border-color: #ddd;
}
.signup {
background-color: #ffffff;
padding: 30px;
border-radius: 10px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
max-width: 400px;
margin: 0 auto;
font-family: Arial, sans-serif;
}
/* Title Styling */
.signup .title {
font-size: 1.8em;
font-weight: 600;
color: #333;
text-align: center;
margin-bottom: 25px;
}
/* Form Group Styling */
.form_group {
margin-bottom: 20px;
}
/* Label Styling */
.sub_title {
font-size: 1em;
color: #333;
margin-bottom: 5px;
display: block;
}
/* Input Styling */
.form_style {
width: 100%;
padding: 12px;
border: 1px solid var(--border-color);
border-radius: 5px;
transition: border-color 0.3s;
font-size: 1em;
}
.form_style:focus {
border-color: var(--primary-color);
outline: none;
box-shadow: 0 0 8px rgba(0, 123, 95, 0.2);
transition: all 0.3s ease;
}
/* Button Styling */
.btn {
width: 100%;
padding: 12px;
font-size: 1em;
font-weight: bold;
color: white;
background-color: var(--primary-color);
border: none;
border-radius: 5px;
cursor: pointer;
transition: background-color 0.3s, transform 0.1s;
}
.btn:hover {
background-color: var(--primary-dark);
}
.btn:active {
transform: scale(0.98);
}
/* Link Styling */
.link {
color: #006048;
text-decoration: none;
font-weight: bold;
outline: none;
}
.link:hover {
text-decoration: underline;
}
.link:focus {
outline: 2px solid #007b5f;
outline-offset: 2px;
}
/* Text under button */
.form_action p {
text-align: center;
font-size: 0.9em;
margin-top: 15px;
}
/* Responsive Styling */
@media (max-width: 500px) {
.signup {
padding: 20px;
max-width: 90%;
margin: 0 auto;
}
.signup .title {
font-size: 1.6em;
}
.btn, .form_style {
font-size: 0.95em;
}
}

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