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

[REVERTED] Fix #12238: Making the question and header sticky in the question editor modal #20127

Merged
merged 6 commits into from
Apr 18, 2024

Conversation

arjen0203
Copy link
Contributor

@arjen0203 arjen0203 commented Apr 3, 2024

Overview

  1. This PR fixes or fixes part of [Contributor Dashboard] Make question sticky in question editor modal #12238
  2. This PR does the following: It makes the question sticky in the editor and in the review modal of the contributor dashboard
  3. (For bug-fixing PRs only) The original bug occurred because: [Explain what
    the cause of the bug was, and which PR introduced it]

Essential Checklist

Please follow the instructions for making a code change.

  • I have linked the issue that this PR fixes in the "Development" section of the sidebar.
  • I have checked the "Files Changed" tab and confirmed that the changes are what I want to make.
  • I have written tests for my code. -> Manually tested since it are css changes, proof provided below.
  • The PR title starts with "Fix #bugnum: " or "Fix part of #bugnum: ...", followed by a short, clear summary of the changes.
  • I have assigned the correct reviewers to this PR (or will leave a comment with the phrase "@{{reviewer_username}} PTAL" if I can't assign them directly).

Proof that changes are correct

Before:
https://github.com/oppia/oppia/assets/14263008/0def067b-f3a8-4053-b099-c5f890660fdc

After:
https://github.com/oppia/oppia/assets/14263008/a9d35a18-7a09-4c99-8883-1c101308815c

Proof of changes in Arabic language

2024-04-03.15-46-14.mov

PR Pointers

@arjen0203 arjen0203 requested review from a team as code owners April 3, 2024 14:01
Copy link

oppiabot bot commented Apr 3, 2024

Assigning @nikitaevg for the first pass review of this PR. Thanks!

@seanlip
Copy link
Member

seanlip commented Apr 3, 2024

@arjen0203 Quick check -- I just manually linked the issue in the Development section, but why did you tick the first checkbox when that wasn't done? (Wanted to understand if there are any process issues here, thanks!)

Copy link
Contributor

@nikitaevg nikitaevg left a comment

Choose a reason for hiding this comment

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

It looks good! But I have a couple concerns, + what Sean said in #12238 (comment)

@@ -142,6 +142,7 @@ export class QuestionSuggestionReviewModalComponent
questionId: string | null = null;
isFirstItem: boolean = true;
isLastItem: boolean = true;
stateContentShouldStayVisibleOnScroll: boolean = true;
Copy link
Contributor

Choose a reason for hiding this comment

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

If this value is true by default and never changed, why not inlining it in html?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is value is now specified inline html

@@ -60,6 +60,7 @@ export class QuestionEditorComponent implements OnInit, OnDestroy {
@Input() question!: Question;
@Input() questionId!: string;
@Input() questionStateData!: State;
@Input() stateContentShouldStayVisibleOnScroll!: boolean;
Copy link
Contributor

Choose a reason for hiding this comment

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

If this input is required, what about other usages of the question-editor? In my understanding you should pass this argument there too.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Every usage of question-editor now has it's value specified

@oppiabot oppiabot bot unassigned nikitaevg Apr 3, 2024
Copy link

oppiabot bot commented Apr 3, 2024

Unassigning @nikitaevg since the review is done.

Copy link

oppiabot bot commented Apr 3, 2024

Hi @arjen0203, it looks like some changes were requested on this pull request by @nikitaevg. PTAL. Thanks!

Copy link
Contributor

@StephenYu2018 StephenYu2018 left a comment

Choose a reason for hiding this comment

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

One concern.

Copy link

oppiabot bot commented Apr 11, 2024

Hi @arjen0203, I'm going to mark this PR as stale because it hasn't had any updates for 7 days. If no further activity occurs within 4 days, it will be automatically closed so that others can take up the issue.
If you are still working on this PR, please make a follow-up commit within 4 days (and submit it for review, if applicable). Please also let us know if you are stuck so we can help you!

@oppiabot oppiabot bot added the stale label Apr 11, 2024
@arjen0203
Copy link
Contributor Author

@arjen0203 Quick check -- I just manually linked the issue in the Development section, but why did you tick the first checkbox when that wasn't done? (Wanted to understand if there are any process issues here, thanks!)

That fault lies with me, reading the warning warning of the PR being auto-closed I wronly assumed it would be added automatically. But it is clear to me now that it should have been done manually

@oppiabot oppiabot bot removed the stale label Apr 12, 2024
Copy link
Contributor Author

@arjen0203 arjen0203 left a comment

Choose a reason for hiding this comment

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

Proccesed feedback

@@ -60,6 +60,7 @@ export class QuestionEditorComponent implements OnInit, OnDestroy {
@Input() question!: Question;
@Input() questionId!: string;
@Input() questionStateData!: State;
@Input() stateContentShouldStayVisibleOnScroll!: boolean;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Every usage of question-editor now has it's value specified

@@ -142,6 +142,7 @@ export class QuestionSuggestionReviewModalComponent
questionId: string | null = null;
isFirstItem: boolean = true;
isLastItem: boolean = true;
stateContentShouldStayVisibleOnScroll: boolean = true;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is value is now specified inline html

@StephenYu2018
Copy link
Contributor

StephenYu2018 commented Apr 12, 2024

@arjen0203 Never force-push changes to your PR. This will lead to your PR being closed.

@arjen0203
Copy link
Contributor Author

arjen0203 commented Apr 12, 2024

@arjen0203 Never force-push changes to your PR. This will lead to your PR being closed.

I just read it as I was going over all the steps of the review process again, my apologies, was trying to amend some changes, won't happen again

@arjen0203 arjen0203 removed their assignment Apr 12, 2024
@arjen0203
Copy link
Contributor Author

PTAL @StephenYu2018, @nikitaevg

Copy link

oppiabot bot commented Apr 14, 2024

Unassigning @nikitaevg since they have already approved the PR.

Copy link
Contributor

@StephenYu2018 StephenYu2018 left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link

oppiabot bot commented Apr 17, 2024

Unassigning @StephenYu2018 since they have already approved the PR.

@Ash-2k3 Ash-2k3 added this pull request to the merge queue Apr 18, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Apr 18, 2024
@Ash-2k3 Ash-2k3 added this pull request to the merge queue Apr 18, 2024
Merged via the queue into oppia:develop with commit 985e84d Apr 18, 2024
77 checks passed
@Ash-2k3
Copy link
Member

Ash-2k3 commented Apr 18, 2024

Thanks @arjen0203 for fixing this. And Congrats on getting your first PR merged at Oppia !!!

@chris7716
Copy link
Contributor

We need to revert this PR cuz it has introduced a regression #20290

@seanlip seanlip changed the title Fix #12238: Making the question and header sticky in the question editor modal [REVERTED] Fix #12238: Making the question and header sticky in the question editor modal May 23, 2024
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.

[Contributor Dashboard] Make question sticky in question editor modal
6 participants