-
Notifications
You must be signed in to change notification settings - Fork 2
F/log reviewer server side filter #35
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
base: main
Are you sure you want to change the base?
Conversation
…m/harvard-edtech/dce-reactkit into f/log-reviewer-server-side-filter
currentPage, | ||
numPages, | ||
loading = false, | ||
onPageChanged, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing the template /* Setup */ block
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See template. This is close but still not the same as our template
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few little things. Great work!
src/components/Pagination.tsx
Outdated
pages.push(i); | ||
} | ||
return pages; | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't need to be a function
src/components/Pagination.tsx
Outdated
const pages = getPageNumbers(); | ||
|
||
return ( | ||
<nav aria-label="Page navigation" className="mt-3"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Give the aria-label a more specific, descriptive text
src/components/LogReviewer.tsx
Outdated
}, | ||
[], | ||
); | ||
// Fetch logs on mount |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add JSDoc
src/components/LogReviewer.tsx
Outdated
onClick={() => { | ||
// Save active filters | ||
activeFiltersRef.current = { | ||
dateFilterState: JSON.parse( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add comment describing the fact that we need to duplicate state
src/components/LogReviewer.tsx
Outdated
// Save active filters | ||
activeFiltersRef.current = { | ||
dateFilterState: JSON.parse( | ||
JSON.stringify(pendingDateFilterState), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make a helper function to clone a JSON object
year={pendingDateFilterState.endDate.year} | ||
month={pendingDateFilterState.endDate.month} | ||
day={pendingDateFilterState.endDate.day} | ||
chooseFromPast |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be an error if rebase was successful. Is it?
src/components/LogReviewer.tsx
Outdated
<LoadingSpinner /> | ||
</div> | ||
) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indentation
@@ -0,0 +1,6 @@ | |||
// Tag filter state |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For all your types, switch to JSDoc and add your Author tag
No description provided.