Improve React Doctor score and badge (#1127)

* fix(react doctor): improve quality score and badge

* fix(react doctor): address review feedback

* fix(review): address final bot feedback
This commit is contained in:
Tommaso Casaburi
2026-05-10 18:25:13 +07:00
committed by GitHub
parent e7a6c377c9
commit 556973a445
47 changed files with 771 additions and 442 deletions
@@ -221,11 +221,11 @@ export const AutoButton = () => {
export const BottomButton = () => {
const { t } = useTranslation();
const handleClick = () => {
const scrollToBottom = () => {
window.scrollTo({ top: document.documentElement.scrollHeight, behavior: 'instant' });
};
return (
<button className='button' onClick={handleClick}>
<button className='button' onClick={scrollToBottom}>
{t('bottom')}
</button>
);
@@ -233,11 +233,11 @@ export const BottomButton = () => {
export const TopButton = () => {
const { t } = useTranslation();
const handleClick = () => {
const scrollToTop = () => {
window.scrollTo({ top: 0, left: 0, behavior: 'instant' });
};
return (
<button className='button' onClick={handleClick}>
<button className='button' onClick={scrollToTop}>
{t('top')}
</button>
);
@@ -507,13 +507,13 @@ export const MobileBoardButtons = () => {
{searchText ? (
<span className={styles.filteredThreadsCount}>
{' '}
{t('search_results_for')}: <strong>{searchText}</strong>
- {t('search_results_for')}: <strong>{searchText}</strong>
</span>
) : (
filteredCount > 0 && (
<span className={styles.filteredThreadsCount}>
{' '}
{t('filtered_threads')}: <strong>{filteredCount}</strong>
- {t('filtered_threads')}: <strong>{filteredCount}</strong>
</span>
)
)}
@@ -714,14 +714,14 @@ export const DesktopBoardButtons = () => {
{isInCatalogView && searchText ? (
<span className={styles.filteredThreadsCount}>
{' '}
{t('search_results_for')}: <strong>{searchText}</strong>
- {t('search_results_for')}: <strong>{searchText}</strong>
</span>
) : (
isInCatalogView &&
filteredCount > 0 && (
<span className={styles.filteredThreadsCount}>
{' '}
{t('filtered_threads')}: <strong>{filteredCount}</strong>
- {t('filtered_threads')}: <strong>{filteredCount}</strong>
</span>
)
)}