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

Moved Cancel and Save buttons positions to bottom #378

Closed

Conversation

INDHU1402
Copy link

Describe your changes

Moved Cancel and Save buttons positions to bottom in Create Hint Page while onboarding

Issue number

Fixes the issue #370

Please ensure all items are checked off before requesting a review:

  • I have performed a self-review of my code.
  • I have included the issue # in the PR.
  • I have labelled the PR correctly.
  • My PR is granular and targeted to one specific feature only.

Copy link
Contributor

coderabbitai bot commented Dec 11, 2024

Walkthrough

The changes made in the GuideTemplate.module.scss file involve a single adjustment to the .optionButtons class, specifically increasing the margin-top from 2rem to 3.5rem. This modification enhances the vertical spacing above the option buttons while leaving the overall layout and other style properties intact.

Changes

File Path Change Summary
frontend/src/templates/GuideTemplate/GuideTemplate.module.scss Updated .optionButtons margin-top from 2rem to 3.5rem.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant GuideTemplate

    User->>GuideTemplate: View Guide
    GuideTemplate->>User: Display Guide with Option Buttons
    User->>GuideTemplate: Interact with Option Buttons
Loading

Tip

CodeRabbit's docstrings feature is now available as part of our Early Access Program! Simply use the command @coderabbitai generate docstrings to have CodeRabbit automatically generate docstrings for your pull request. This feature will be included in our Pro Plan when released.


📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between da44fd4 and 61ed3a6.

📒 Files selected for processing (1)
  • frontend/src/templates/GuideTemplate/GuideTemplate.module.scss (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • frontend/src/templates/GuideTemplate/GuideTemplate.module.scss

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:

‼️ IMPORTANT
Auto-reply has been disabled for this repository in the CodeRabbit settings. The CodeRabbit bot will not respond to your replies unless it is explicitly tagged.

  • 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 generate docstrings to generate docstrings for this PR. (Beta)
  • @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.

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
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: 0

🧹 Outside diff range and nitpick comments (1)
frontend/src/templates/GuideTemplate/GuideTemplate.module.scss (1)

48-48: Yo dawg, I heard you like robust layouts!

While the margin works, here's a more bulletproof way to stick those buttons to the bottom, no matter the content height. It's like mom's spaghetti - it never fails!

Consider this flex layout approach:

 .container {
+    display: flex;
+    flex-direction: column;
+    min-height: 100%;

     .popup {
+        display: flex;
+        flex-direction: column;
+        flex: 1;
     }

     .content {
+        flex: 1;
     }

     .optionButtons {
         display: flex;
         justify-content: flex-end;
-        margin-top: 4rem;
         gap: 1rem;
+        margin-top: auto;
     }
 }

This way, the buttons will always stick to the bottom, regardless of the content height. No more sweaty palms worrying about spacing!

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between f13355b and 50cbbfd.

📒 Files selected for processing (1)
  • frontend/src/templates/GuideTemplate/GuideTemplate.module.scss (1 hunks)
🔇 Additional comments (1)
frontend/src/templates/GuideTemplate/GuideTemplate.module.scss (1)

48-48: Yo, the margin change looks good for now!

The increased margin-top pushes those buttons down like gravity, just what we needed. It's a simple fix that gets the job done.

@gorkem-bwl gorkem-bwl requested a review from swoopertr December 12, 2024 04:48
@gorkem-bwl
Copy link
Contributor

Can you please send a screenshot too?

@INDHU1402
Copy link
Author

Sure @gorkem-bwl, after the change it looks like this.

Screenshot 2024-12-12 at 12 40 22 PM

@gorkem-bwl
Copy link
Contributor

All the gaps here should be the same. Please fix the bottom gap and we're good to go!

image

@INDHU1402
Copy link
Author

Hey @gorkem-bwl, fixed the bottom gap! (I assume this is what you meant)

Screenshot 2024-12-13 at 1 27 16 PM

@gorkem-bwl
Copy link
Contributor

gorkem-bwl commented Dec 14, 2024

Hey @gorkem-bwl, fixed the bottom gap! (I assume this is what you meant)

Please move the Cancel/Save buttons up to the purple line and we're done here!

image

@INDHU1402
Copy link
Author

Sure, this is how it looks now.

Screenshot 2024-12-14 at 3 01 44 PM

@gorkem-bwl - Next time let's decide the final UI and then will do the change rather than hopping frequently

@gorkem-bwl
Copy link
Contributor

@gorkem-bwl - Next time let's decide the final UI and then will do the change rather than hopping frequently

You are right - shouldn't have happened. Thanks for the heads up.

@erenfn erenfn self-requested a review December 16, 2024 17:58
Copy link
Collaborator

@erenfn erenfn left a comment

Choose a reason for hiding this comment

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

change the target branch to create-hint-design, this should be merged to develop with #306

@INDHU1402 INDHU1402 changed the base branch from master to create-hint-design December 17, 2024 07:47
@INDHU1402 INDHU1402 requested a review from erenfn December 17, 2024 08:02
@erenfn
Copy link
Collaborator

erenfn commented Dec 18, 2024

It seems that this issue is already solved in #306 However, thank you for your time

@erenfn erenfn closed this Dec 18, 2024
@INDHU1402
Copy link
Author

Cool, thanks for letting me know.
PS : If possible, please close all unnecessary issues so that it doesn't waste anyone's time in future.

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.

3 participants