From 35be4bdfd541d880630948d00fdb3dac5437f318 Mon Sep 17 00:00:00 2001 From: Christian Fehmer Date: Thu, 6 Nov 2025 13:30:19 +0100 Subject: [PATCH 1/3] impr(leaderboard): fix icons on friend leaderboards (@fehmer) (#7086) --- frontend/src/html/pages/leaderboards.html | 17 ++++++++++++-- frontend/src/styles/leaderboards.scss | 16 ++++++++++++++ frontend/src/ts/pages/leaderboards.ts | 27 ++++++++++------------- 3 files changed, 43 insertions(+), 17 deletions(-) diff --git a/frontend/src/html/pages/leaderboards.html b/frontend/src/html/pages/leaderboards.html index 04b2e8eb5885..501c423798a4 100644 --- a/frontend/src/html/pages/leaderboards.html +++ b/frontend/src/html/pages/leaderboards.html @@ -49,8 +49,21 @@ - - + + - + + - +
# + + + + + + # + + + name wpm diff --git a/frontend/src/styles/leaderboards.scss b/frontend/src/styles/leaderboards.scss index 76dd29ed0454..de63d2e27e51 100644 --- a/frontend/src/styles/leaderboards.scss +++ b/frontend/src/styles/leaderboards.scss @@ -161,10 +161,26 @@ padding: var(--padding); } + .globalRank { + i { + display: none; + } + span { + display: inline; + } + } &.friendsOnly { td:first-child { display: table-cell; } + .globalRank { + i { + display: inline; + } + span { + display: none; + } + } } td:first-child { display: none; diff --git a/frontend/src/ts/pages/leaderboards.ts b/frontend/src/ts/pages/leaderboards.ts index 54aec813a5c4..888f6a3ac3c1 100644 --- a/frontend/src/ts/pages/leaderboards.ts +++ b/frontend/src/ts/pages/leaderboards.ts @@ -444,10 +444,8 @@ function buildTableRow(entry: LeaderboardEntry, me = false): HTMLElement { } element.dataset["uid"] = entry.uid; element.innerHTML = ` - ${entry.friendsRank ?? ""}${ - entry.rank === 1 ? '' : entry.rank - }${formatRank(entry.friendsRank)}${formatRank(entry.rank)}
@@ -504,9 +502,7 @@ function buildWeeklyTableRow( element.dataset["uid"] = entry.uid; element.innerHTML = `
${ - entry.rank === 1 ? '' : entry.rank - }${formatRank(entry.rank)}
@@ -718,9 +714,7 @@ function fillUser(): void { }; const html = ` -
${ - rank === 1 ? '' : rank - }
+
${formatRank(rank)}
You (${percentileString})
${diffText}
@@ -811,11 +805,7 @@ function fillUser(): void { }; const html = ` -
${ - userData.rank === 1 - ? '' - : userData.rank - }
+
${formatRank(userData.rank)}
You (${percentileString})
${diffText}
@@ -1390,6 +1380,13 @@ function updateTimeText( text.attr("aria-label", localDateString); } +function formatRank(rank: number | undefined): string { + if (rank === undefined) return ""; + if (rank === 1) return ''; + + return rank.toString(); +} + $(".page.pageLeaderboards .jumpButtons button").on("click", function () { const action = $(this).data("action") as Action; if (action !== "goToPage") { From feb91bdb6143bc61863a2f1180c9d0943655aae5 Mon Sep 17 00:00:00 2001 From: Adam Al Shouli Date: Thu, 6 Nov 2025 16:26:41 +0300 Subject: [PATCH 2/3] style: add space between connected sentences in security policy (@thedev0ps) (#7078) ### Description ### Checks - [ ] Adding quotes? - [ ] Make sure to include translations for the quotes in the description (or another comment) so we can verify their content. - [ ] Adding a language? - Make sure to follow the [languages documentation](https://github.com/monkeytypegame/monkeytype/blob/master/docs/LANGUAGES.md) - [ ] Add language to `packages/schemas/src/languages.ts` - [ ] Add language to exactly one group in `frontend/src/ts/constants/languages.ts` - [ ] Add language json file to `frontend/static/languages` - [ ] Adding a theme? - Make sure to follow the [themes documentation](https://github.com/monkeytypegame/monkeytype/blob/master/docs/THEMES.md) - [ ] Add theme to `packages/schemas/src/themes.ts` - [ ] Add theme to `frontend/src/ts/constants/themes.ts` - [ ] Add theme css file to `frontend/static/themes` - [ ] Add some screenshot of the theme, especially with different test settings (colorful, flip colors) to your pull request - [ ] Adding a layout? - [ ] Make sure to follow the [layouts documentation](https://github.com/monkeytypegame/monkeytype/blob/master/docs/LAYOUTS.md) - [ ] Add layout to `packages/schemas/src/layouts.ts` - [ ] Add layout json file to `frontend/static/layouts` - [ ] Adding a font? - Make sure to follow the [themes documentation](https://github.com/monkeytypegame/monkeytype/blob/master/docs/FONTS.md) - [ ] Add font file to `frontend/static/webfonts` - [ ] Add font to `packages/schemas/src/fonts.ts` - [ ] Add font to `frontend/src/ts/constants/fonts.ts` - [x] Check if any open issues are related to this PR; if so, be sure to tag them below. - [x] Make sure the PR title follows the Conventional Commits standard. (https://www.conventionalcommits.org for more info) - [x] Make sure to include your GitHub username prefixed with @ inside parentheses at the end of the PR title. Closes # --- frontend/src/security-policy.html | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/frontend/src/security-policy.html b/frontend/src/security-policy.html index 939faa39dd7d..4e9a70600ef5 100644 --- a/frontend/src/security-policy.html +++ b/frontend/src/security-policy.html @@ -137,7 +137,8 @@

How to Disclose a Vulnerability

email . - For non-security related platform bugs, follow the bug submission +  For non-security related platform bugs, follow the bug + submission How to Disclose a Vulnerability . - Include as much detail as possible to ensure reproducibility. At a - minimum, vulnerability disclosures should include: +  Include as much detail as possible to ensure reproducibility. At + a minimum, vulnerability disclosures should include:

  • Vulnerability Description
  • From bf37029f6cad1a980bdd1c09d5061c5d872a27f9 Mon Sep 17 00:00:00 2001 From: Miodec Date: Tue, 4 Nov 2025 21:26:30 +0100 Subject: [PATCH 3/3] fix: 404 page not working --- frontend/src/ts/controllers/route-controller.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/frontend/src/ts/controllers/route-controller.ts b/frontend/src/ts/controllers/route-controller.ts index 9f70dd3d9a92..2c0eda4b504f 100644 --- a/frontend/src/ts/controllers/route-controller.ts +++ b/frontend/src/ts/controllers/route-controller.ts @@ -47,8 +47,8 @@ type Route = { const route404: Route = { path: "404", - load: async () => { - await PageController.change("404"); + load: async (_params, options) => { + await PageController.change("404", options); }, }; @@ -224,7 +224,12 @@ async function router(options = {} as NavigateOptions): Promise { }; if (match === undefined) { - await route404.load({}, {}); + await route404.load( + {}, + { + force: true, + } + ); return; }