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

Improve the design of various components #2

Merged
merged 46 commits into from Aug 4, 2021

Conversation

double-beep
Copy link
Contributor

  • Use GM_setValue, GM_getValue and GM_deleteValue if the user uses a userscript manager, otherwise store config in localStorate.
  • Append the config modal to the body. Convert margin to padding to fix an issue where part of the outline of the switch was hidden.
  • Use Stacks' user cards for the user cards of suggestors, editors, and askers/answerers. before/after
  • Use modern async/await syntax on fetches instead of .then()/.catch().
  • Show the user cards not found error message when the edit has been suggested on a deleted answer.

Copy link
Contributor

@Oaphi Oaphi left a comment

Choose a reason for hiding this comment

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

I left some comments but they aren't blocking - LGTM

StackReviewSuggestedEditsRework.user.js Outdated Show resolved Hide resolved
StackReviewSuggestedEditsRework.user.js Outdated Show resolved Hide resolved
StackReviewSuggestedEditsRework.user.js Outdated Show resolved Hide resolved
StackReviewSuggestedEditsRework.user.js Outdated Show resolved Hide resolved
Keep the margin -> padding change.
@double-beep double-beep marked this pull request as ready for review June 27, 2021 10:35
@double-beep double-beep changed the base branch from main to temporary July 2, 2021 08:37
Copy link
Owner

@Scratle Scratle left a comment

Choose a reason for hiding this comment

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

I tried this with buttons and not moving the progress. "s-btn__xs" and padding seems do-able to me. No "s-btn__xs" even without padding is a bit too cramped up. This was supposed to be a comment on this commit, but I can't figure out how to do that.

Copy link
Owner

@Scratle Scratle left a comment

Choose a reason for hiding this comment

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

(deleted) Sorry about this, but I'm not allowed to delete a "Review changed" comment

Copy link
Contributor

@Oaphi Oaphi left a comment

Choose a reason for hiding this comment

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

this is a test review comment

Copy link
Contributor

@Oaphi Oaphi left a comment

Choose a reason for hiding this comment

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

We can ditch the [...el.querySelectorAll("...")].forEach and just do: el.querySelectorAll("...").forEach as the method exists on the collection returned

Copy link
Contributor

@Oaphi Oaphi left a comment

Choose a reason for hiding this comment

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

btw, I suppose we can move the "pe-none" class to config object

@@ -3239,10 +3239,8 @@

radios.forEach((radio) => {
Copy link
Contributor

@Oaphi Oaphi Jul 2, 2021

Choose a reason for hiding this comment

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

We should probably optimize here:

radios.forEach(({ style }) => {
   style.borderLeft = radioWithBorders ? `${radioSeperatorColour} solid ${radioSeperatorSize}px` : "none";
});

Copy link
Contributor

@Oaphi Oaphi left a comment

Choose a reason for hiding this comment

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

We should probably wrap the new Date().toISOString().replace("T", " ") into a utility

@double-beep double-beep requested a review from Scratle July 2, 2021 18:42
@double-beep double-beep changed the base branch from temporary to mergeBranch July 23, 2021 05:16
@Scratle Scratle merged commit 31b8baa into Scratle:mergeBranch Aug 4, 2021
@double-beep double-beep deleted the cleanup branch August 10, 2021 19:41
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.

None yet

3 participants