Commit graph

11916 commits

Author SHA1 Message Date
Nad Alaba
33a6bc09e3
refactor(caret): move active word element offset to test-state and remove .smoothScroller (@NadAlaba) (#6541) 2025-06-23 14:36:36 +02:00
Miodec
ced4b6e162 impr(lazy mode): support replacing 2 characters with one
also adds lazy mode to yiddish
closes #6321
2025-06-22 10:49:17 +02:00
Nad Alaba
5ca47e116b
impr(tape mode): support RTL languages (@NadAlaba) (#5748)
### Description

1. Support RTL in tape mode:
- In `scrollTape()`: flip the sign of `#words.margin-left` and add
`.word.margin-right` to center first letter in RTL.
- In `Caret.getTargetPositionLeft()`: flip the direction of tapeMargin
in RTL.
   - Remove restriction on RTL tape mode from test-logic.ts.

2. Support zero-width characters in tape mode:
- Subtract the width of the last letter that has a positive width if the
current letter has a zero width (e.g, diacritics). This is needed when
calculation is based on letter widths instead of letter position, which
is done in caret.ts when tape=word, and in `scrollTape()` when
tape=letter.

3. Remove the width change of `#words` in tape mode to 200vw because
it's not needed anymore now that we're using `white-space: nowrap`:
- Also adjust the limit of `.afterNewline.margin-left` to be 3 times the
new width of `#words` which is now equal to `#wordsWrapper.width` by
default.

4. Make `.word.height` in `.withLigature` langs similar to their height
in english:
- Imitate the appearance and behavior of `inline-block` `<letter>`s in
`.withLigatures` lanuages. These languages make the display of
`<letter>` elements `inline` in order to allow the joining of letters.
However, this causes `<letter>`'s `border-bottom` to be ignored, which
changes `.word` height, so we add a `padding-bottom` to the `.word` in
that case.
- Also, `inline` `<letter>`s overflow the `#wordWrapper` without
wrapping (e.g, when `maxLineWidth` = 20ch and we type 30 letters), so we
add the property `overflow-wrap: anywhere`, but we don't allow `.hints`
to inherit this property.
- P.S, it is necessary that all `.word`s have the same height (with and
without ligatures), because we now set the height of `.beforeNewline`s
in css, and we depend on these elements to have the same height as
`.word`s so that the user won't feel a vertical shift in lines in tape
mode.

5. Animate turning off tape mode in `updateWordsMargin()` if
`SmoothLineScroller` is on.

6. Block removing words at the first call of `scrollTape()`:
- Because the inline style of `#words.margin-left` may be negative when
restarting the test, making `scrollTape()` start when the first word is
overflown to the left, which makes `scrollTape()` remove that word (this
bug affects LTR and RTL langs).

closes #3923

---------

Co-authored-by: Jack <jack@monkeytype.com>
2025-06-18 12:02:43 +02:00
Christian Fehmer
85543ffa19
fix(docker): fix deeplinks and update documentation (@fehmer) (#6640)
- support deep links like `/login`
- fix some typos

closes #6628

---------

Co-authored-by: Jack <jack@monkeytype.com>
2025-06-17 12:52:52 +02:00
acdpsn
ebfa8bea61
fix(quotes): gladiator quote (@acdpsn) (#6626)
### Description

Update a Gladiator quote to fix a typo and fix the title to properly
reference the movie name.

### 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/contracts/src/schemas/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/contracts/src/schemas/themes.ts`
  - [ ] Add theme to `frontend/src/ts/constants/themes.ts`
  - [ ] Add theme css file to `frontend/static/themes`
- Also please add a screenshot of the theme, it would be extra awesome
if you do so!
- [ ] Adding a layout?
- [ ] Make sure to follow the [layouts
documentation](https://github.com/monkeytypegame/monkeytype/blob/master/docs/LAYOUTS.md)
  - [ ] Add layout to `packages/contracts/src/schemas/layouts.ts`
  - [ ] Add layout json file to `frontend/static/layouts` 
- [ ] Check if any open issues are related to this PR; if so, be sure to
tag them below.
- [ ] Make sure the PR title follows the Conventional Commits standard.
(https://www.conventionalcommits.org for more info)
- [ ] Make sure to include your GitHub username prefixed with @ inside
parentheses at the end of the PR title.

<!-- label(optional scope): pull request title (@your_github_username)
-->

<!-- I know I know they seem boring but please do them, they help us and
you will find out it also helps you.-->

Closes #

<!-- the issue(s) your PR resolves if any (delete if that is not the
case) -->
<!-- please also reference any issues and or PRs related to your pull
request -->
<!-- Also remove it if you are not following any issues. -->

<!-- pro tip: you can mention an issue, PR, or discussion on GitHub by
referencing its hash number e.g:
[#1234](https://github.com/monkeytypegame/monkeytype/pull/1234) -->

<!-- pro tip: you can press . (dot or period) in the code tab of any
GitHub repo to get access to GitHub's VS Code web editor Enjoy! :) -->
2025-06-16 14:45:13 +02:00
Derek Yuan
e8cbe3ba15
impr(quotes): ad 60 Chinese Simplified Quotes (@derekyuan1000) (#6620)
### Description
60 more famous Chinese Simplified Quotes
<!-- Please describe the change(s) made in your PR -->

### Checks

- [x] Adding quotes?
- [x] Make sure to include translations for the quotes in the
description (or another comment) so we can verify their content.

Closes #

<!-- the issue(s) your PR resolves if any (delete if that is not the
case) -->
<!-- please also reference any issues and or PRs related to your pull
request -->
<!-- Also remove it if you are not following any issues. -->

<!-- pro tip: you can mention an issue, PR, or discussion on GitHub by
referencing its hash number e.g:
[#1234](https://github.com/monkeytypegame/monkeytype/pull/1234) -->

<!-- pro tip: you can press . (dot or period) in the code tab of any
GitHub repo to get access to GitHub's VS Code web editor Enjoy! :) -->



### Translations:

- "Heaven progresses vigorously; a gentleman should persist in
self-improvement." - **"id": 241**

- "The sea accommodates hundreds of rivers, only with tolerance can one
be great." - **"id": 242**

- "A journey of a thousand miles begins with a single step." - **"id":
243**

- "To learn without thinking is labor lost; to think without learning is
dangerous." - **"id": 244**

- "A keen learner does not shy away from asking questions." - **"id":
245**

- "Those who are content are always happy." - **"id": 246**

- "Where there is a will, there is a way." - **"id": 247**

- "Read thousands of books and travel thousands of miles." - **"id":
248**

- "Do not impose on others what you do not desire for yourself." -
**"id": 249**

- "The road is long and winding; I will seek diligently." - **"id":
250**

- "Without accumulating small steps, one cannot reach a thousand miles."
- **"id": 251**

- "Knowing others is intelligence; knowing oneself is true wisdom." -
**"id": 252**

- "Teaching others to seek truth is the essence of education." - **"id":
253**

- "Isn't it a joy to have friends come from afar?" - **"id": 254**

- "Do not be joyous over material things, nor be sad over personal
losses." - **"id": 255**

- "When heaven is about to assign a great responsibility to a person, it
will first temper their will." - **"id": 256**

- "Skill is honed by diligence, while laziness destroys it." - **"id":
257**

- "The strength of a horse is known through its endurance; the heart of
a person is revealed over time." - **"id": 258**

- "Without enduring the bitter cold, how can one smell the fragrant plum
blossoms?" - **"id": 259**

- "Reading a book a hundred times reveals its meaning." - **"id": 260**

- "Lessons from past events serve as guidance for future actions." -
**"id": 261**

- "Those close to vermilion become red; those close to ink become
black." - **"id": 262**

- "Dripping water can penetrate stone; a rope saw can cut wood." -
**"id": 263**

- "Without entering the tiger's den, how can one catch a tiger cub?" -
**"id": 264**

- "The loss of the old horse might be a blessing." - **"id": 265**

- "Peach and plum trees do not speak, yet a path forms beneath them." -
**"id": 266**

- "Without rules, one cannot achieve a circle or a square." - **"id":
267**

- "Everyone has strengths and weaknesses." - **"id": 268**

- "Those who understand are not as good as those who love; those who
love are not as good as those who find joy." - **"id": 269**

- "A gentleman is harmonious yet distinct; a petty person is identical
yet disharmonious." - **"id": 270**

- "A thousand-mile gift of goose feathers is light in value but heavy in
sentiment." - **"id": 271**

- "An inch of time is worth an inch of gold, but gold cannot buy an inch
of time." - **"id": 272**

- "Bitter medicine is good for illness; harsh words are beneficial for
action." - **"id": 273**

- "A thousand troops are easy to find, but a good general is hard to
come by." - **"id": 274**

- "It's not the slow pace that is to be feared, but standing still." -
**"id": 275**

- "From a high pole, one can go further." - **"id": 276**

- "A single leaf can block the view of Mount Tai." - **"id": 277**

- "Unconsciously, time flows quietly." - **"id": 278**

- "Since ancient times, who has not died? Let my loyal heart shine
through history." - **"id": 279**

- "With a thousand hammers and chisels, one can emerge from the
mountains; facing fierce flames is nothing." - **"id": 280**

- "Without knowing the true face of Mount Lu, one is limited by being in
the mountain." - **"id": 281**

- "When one reaches the summit, they can see all the mountains as
small." - **"id": 282**

- "Fallen petals are not heartless; they turn into spring mud to protect
the flowers." - **"id": 283**

- "If life were just as it was at first sight, what sorrow would autumn
winds bring to painted fans?" - **"id": 284**

- "Life is like a dream; let us toast to the moon over the river." -
**"id": 285**

- "The spring silkworms die only when their silk is exhausted; the wax
torch turns to ash only when the tears have dried." - **"id": 286**

- "To see a thousand miles ahead, one must climb another floor." -
**"id": 287**

- "Heaven has given me talent for a purpose; even if I spend a fortune,
it will return." - **"id": 288**

- "Do not worry about having no friends on the road; who in the world
does not know you?" - **"id": 289**

- "A thousand sails pass by the sunken boat; a thousand trees bloom in
front of the sick tree." - **"id": 290**

- "In the midst of mountains and rivers, one may think there is no way;
but within the shadows of willows and flowers, there lies another
village." - **"id": 291**

- "After gathering a hundred flowers to make honey, for whom do you toil
and for whom do you sweeten?" - **"id": 292**

- "Fallen red clouds fly alongside solitary wild ducks; autumn waters
blend with the long sky in one color." - **"id": 293**

- "Life is like a journey against the current; I too am a traveler." -
**"id": 294**

- "In times of joy, one should enjoy thoroughly; do not let the golden
cup face the moon empty." - **"id": 295**

- "The spring breeze once again greens the southern bank; when will the
bright moon shine on my return?" - **"id": 296**

- "When one strikes water for three thousand miles, one trusts in life
for two hundred years." - **"id": 297**

- "If the nation benefits from life or death, how can one avoid fortune
or misfortune?" - **"id": 298**

- "Life is like a white horse passing through a crack; it is all too
sudden." - **"id": 299**

- "A thousand-mile dike collapses from an ant's nest." - **"id": 300**

- "Without climbing a high mountain, one cannot know the height of
heaven; without approaching a deep stream, one cannot know the thickness
of earth." - **"id": 301**

- "Those who know their insufficiencies are always present." - **"id":
302**

- "Reading ten thousand books, writing as if inspired by a divine
spirit." - **"id": 303**

- "Do not forget your original intention, and you will achieve your
goal." - **"id": 304**

- "A journey of a thousand miles begins with a single step." - **"id":
305**

- "Learning has no limits." - **"id": 306**

- "Knowing shame leads to courage." - **"id": 307**

- "Do not worry about others not knowing you; worry about not knowing
others." - **"id": 308**

- "One should help others achieve their goals while seeking their own."
- **"id": 309**

- "To know what is to know, and to not know what is not to know, is
knowledge." - **"id": 310**

- "Think thrice before acting." - **"id": 311**

- "Review the old to learn the new." - **"id": 312**

- "To study and practice regularly, is that not a joy?" - **"id": 313**

- "Those who know are not as good as those who love." - **"id": 314**

- "A keen learner does not shy away from asking questions." - **"id":
315**

- "A gentleman is open and relaxed; a petty person is always anxious." -
**"id": 316**

- "Do not impose on others what you do not desire for yourself." -
**"id": 317**

- "When three people walk together, there must be a teacher among them."
- **"id": 318**

- "To study without fatigue, to teach without weariness." - **"id":
319**

- "The wise are not confused; the benevolent are not worried; the brave
are not afraid." - **"id": 320**

- "A gentleman seeks from himself; a petty person seeks from others." -
**"id": 321**

- "A gentleman helps others to succeed but does not participate in their
wrongs." - **"id": 322**

- "A gentleman cherishes virtue, while a petty person cherishes land. A
gentleman cherishes punishment, while a petty person cherishes favor." -
**"id": 323**

- "A gentleman understands righteousness; a petty person understands
profit." - **"id": 324**

- "In the cold of winter, only then do we know the pine and cypress are
the last to wither." - **"id": 325**

- "Do not worry about lacking a position; worry about how to stand. Do
not worry about being unknown; seek to be known." - **"id": 326**

- "The wise love water; the benevolent love mountains." - **"id": 327**

- "A gentleman is cautious in speech but quick in action." - **"id":
328**

- "A gentleman is not a tool." - **"id": 329**

- "A gentleman is harmonious yet distinct." - **"id": 330**
2025-06-16 14:43:23 +02:00
Seif Soliman
26a39eb7ca
fix(commandline): prevent unwanted scrolling on initial mouse entry (@byseif21) (#6615)
### Description

fix this weird behavior scroll:


https://github.com/user-attachments/assets/73a7c9f2-f584-4d4a-9932-dbb565d99be6
2025-06-16 14:32:07 +02:00
j5155
bf4f1e08a6
impr(quotes): Add English quotes from Andor S1 (@j5155) (#6585)
### Description

I added some quotes of various lengths from Andor season 1. 

### Checks

- [x] 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/contracts/src/schemas/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/contracts/src/schemas/themes.ts`
  - [ ] Add theme to `frontend/src/ts/constants/themes.ts`
  - [ ] Add theme css file to `frontend/static/themes` 
- [ ] Adding a layout?
- [ ] Make sure to follow the [layouts
documentation](https://github.com/monkeytypegame/monkeytype/blob/master/docs/LAYOUTS.md)
  - [ ] Add layout to `packages/contracts/src/schemas/layouts.ts`
  - [ ] Add layout json file to `frontend/static/layouts` 
- Also please add a screenshot of the theme, it would be extra awesome
if you do so!
  
- [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.

<!-- label(optional scope): pull request title (@your_github_username)
-->

<!-- I know I know they seem boring but please do them, they help us and
you will find out it also helps you.-->


<!-- the issue(s) your PR resolves if any (delete if that is not the
case) -->
<!-- please also reference any issues and or PRs related to your pull
request -->
<!-- Also remove it if you are not following any issues. -->

<!-- pro tip: you can mention an issue, PR, or discussion on GitHub by
referencing its hash number e.g:
[#1234](https://github.com/monkeytypegame/monkeytype/pull/1234) -->

<!-- pro tip: you can press . (dot or period) in the code tab of any
GitHub repo to get access to GitHub's VS Code web editor Enjoy! :) -->
2025-06-16 14:27:40 +02:00
Miodec
dabaa14341 chore: add insane badge 2025-06-16 13:11:22 +02:00
Miodec
9891dac323 chore(release script): remove validate-json step if only running in the backend 2025-06-16 12:13:36 +02:00
Miodec
63b63ffa9c chore: update plugins overrides 2025-06-14 15:33:52 +02:00
Miodec
4c05dd8326 chore: bump oxlint version 2025-06-14 14:43:05 +02:00
Miodec
2d008461ed chore: catch firebase internal errors when trying to auth 2025-06-14 14:11:05 +02:00
Miodec
8843c50d71 impr(account): add restarts per test and highest wpm to activity graph 2025-06-12 16:51:46 +02:00
Miodec
9d28a42c73 chore: remove non word 2025-06-12 15:35:14 +02:00
Nad Alaba
238a2c72e4
fix(wordsInput): prevent #wordsInput from overflowing the #wordsWrapper (@NadAlaba) (#6610)
### Description

in tape mode, if a long word is wider than the #wordsWrapper, then
#wordsInput may overflow to the right causing a horizontal scroll to
keep it in view. This limits its width so that it ends with the
#wordsWrapper.


https://github.com/user-attachments/assets/a9266407-a21c-43c0-9304-e683c6c2ce04
2025-06-04 13:16:19 +02:00
Seif Soliman
ec6e76b12e
chore: fix typo in issue template (@byseif21) (#6613) 2025-06-04 10:59:44 +02:00
Viktor
502f1c52b8
impr: add words to Odin, remove non-existing complex_* (@dayllenger) (#6607)
### Description

Added a few missing keywords, some common attributes and procedures.
Removed complex_double/complex_float (not sure why they were there).

### Checks

- [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.
2025-06-04 10:58:43 +02:00
Jack
4bb431b98a
perf: fix account page getting slower with every load (@miodec) (#6606)
Stacking event listeners go brrrrrrr
2025-05-29 17:00:56 +02:00
Miodec
af86a2d73d style: align ad content to the center 2025-05-29 15:15:18 +02:00
Seif Soliman
0600b25cda
fix(settings page): ui not updating on favorite themes change via commandline (@byseif21) (#6567)
### Description
When using the command line to add or remove a theme from favorites
while on the settings page, the favorites UI would not reflect the
changes until the user manually refreshed the page or changed the theme.
This caused confusion, despite the changes being correctly saved in the
config.

**Solution**
Added a ConfigEvent subscription in theme-picker.ts to listen for
"favThemes" updates. If the active page is "settings", the UI is now
refreshed immediately by calling refreshPresetButtons().
2025-05-29 13:35:21 +02:00
Miodec
04fbd81c10 chore: bump oxlint version 2025-05-29 13:23:13 +02:00
Seif Soliman
0bf76e8990
impr: add quick theme favorite indicator to the commandline & footer (@byseif21, @miodec) (#6460)
### Add Quick Favorite ~~Toggle~~ **Indicator** and Prioritized
Favorites to Theme Picker

This pull request adds a new feature to MonkeyType’s theme picker &
(**current theme button** in the **footer**) ~~making it super easy for
users to save/unsave and access their favorite themes instead of going
to the settings or any other thing~~ to display a small **star icon**
indicating whether the **the theme** is marked as a favorite. Favorited
themes appear at the top of the theme list for quick access.

~~Also, I added a small heart icon next to the current theme button in
the footer to quickly favorite the active theme with one click—making it
even easier to save a new favorite without needing to open the list.~~

The star icon next to the current theme button **only acts as a visual
indicator**, showing whether the current theme is a favorite or not.
**No longer clickable**.

---

**User Benefits:**

* **Favorites at the Top:**
Favorite themes appear first in the theme picker, so you can switch to
them instantly without searching through the list.

* ~~**One-Click Star Toggle:**~~
~~Click a star next to any theme to favorite or unfavorite it right in
the picker. No need to dig through settings, saving you time and
effort.~~

* **Visual Indicator for Active Theme:**
A small star icon beside the current theme button tells you at a glance
whether your active theme is in your favorites—without needing to open
the list.

---

**What I Did:**

* Added a star icon appears next to the favorite themes ~~each theme in
the theme picker for quick favoriting or unfavoriting.~~
* Made favorite themes show up at the top of the list for easy access.
* ~~Added a small heart icon next to the current theme button in the
footer to favorite the active theme quickly.~~
* Added a small star icon next to the current theme button in the footer
**as an indicator only** — it shows whether the active theme is a
favorite, but **is not clickable**.
* ~~- Added notifications to confirm when a theme is favorited or
unfavorited.~~

---

**Preview:** (**OUTDATED**)


[https://github.com/user-attachments/assets/5bba15c4-edbb-4577-abfe-fd581f196b98](https://github.com/user-attachments/assets/5bba15c4-edbb-4577-abfe-fd581f196b98)

---

### 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 or a theme?

* [ ] If it’s a language, did you edit `_list.json`, `_groups.json`, and
add `languages.json`?
  * [ ] If it’s a theme, did you add the theme.css?

* Also please add a screenshot of the theme, it would be extra awesome
if you do so!
* [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/](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.

---

---------

Co-authored-by: Miodec <jack@monkeytype.com>
Co-authored-by: Nginearing <142851004+Nginearing@users.noreply.github.com>
Co-authored-by: Pavel Ivashkov <paiv@users.noreply.github.com>
Co-authored-by: Christian Fehmer <fehmer@users.noreply.github.com>
Co-authored-by: siilyg <149881151+siily-g@users.noreply.github.com>
Co-authored-by: Omar Abdelrahman Abbas <tryomarabbas@gmail.com>
2025-05-29 13:15:44 +02:00
Seif Soliman
2d878b8700
fix(commandline): improve caching to fix stale checkmark and UI state (@byseif21, @fehmer) (#6586)
### Description

Previously, when selecting a language via the text button on the test
page, the checkmark (fa-check) in the commandline language list wouldn't
update until a page refresh. This was due to the commandline's caching
mechanism not detecting changes triggered outside its own control.

Although it first appeared to be a language-specific issue, it was later
identified that the caching logic was generally insufficient — it didn’t
account for updates to the active command state or configuration flags
like usingSingleList.

## Solution
Fixed the caching logic in the commandline module by tracking a more
complete internal state. The system now correctly detects changes in the
command list, active state, and configuration, and rebuilds the list UI
when necessary.

## Technical Details
- The commandline uses a caching mechanism (`lastList`) to avoid
rebuilding the HTML if the list hasn't changed done in #6559
- Replaced the old lastList cache with a new lastState object that
stores: the list of commands, each with its isActive flag, the
usingSingleList configuration flag
- Improved the cache comparison logic, uses areSortedArraysEqual to
compare command lists including active state ,compares the
usingSingleList flag
- Previously, this cache wasn't being cleared when the language changed
through the text button
- Now we clear the cache on changes, forcing a rebuild of the list with
the correct checkmark

## Performance Impact
- Minimal performance impact
- The list is only rebuilt when:
  1. The language actually changes
  2. The list content changes
  3. The input value changes
- The caching mechanism still prevents unnecessary rebuilds in all other
cases

## Testing
- [x] Language selection through text button updates checkmark
immediately
- [x] Language selection through commandline works as before
- [x] No unnecessary rebuilds when language hasn't changed
- [x] Checkmark appears next to correct language in all cases
2025-05-27 17:37:43 +02:00
Miodec
5695245c86 chore: release v25.22.0 2025-05-27 17:17:48 +02:00
Christian Fehmer
3b0cf16faf
perf: use cache in local-storage-with-schema (@fehmer) (#6596) 2025-05-27 17:12:05 +02:00
Seif Soliman
b26e1d2dba
chore: correct text in difficulty settings descriptions (@byseif21) (#6590)
### Description

The is minor but I think it should be "typing test" not "type test"
2025-05-27 17:00:46 +02:00
Christian Fehmer
d6ae7cf7c4
fix: compatability check header shown if client is using cached responses (@fehmer) (#6602)
If frontend and backend are deployed with a new COMPATABILITY_CHECK
header frontend might show the backend version is lower because of the
http header of a cached response.

Adding the COMPATABILITY_CHECK version as part of the etag fixes this.
2025-05-27 16:59:49 +02:00
Christian Fehmer
093a17b15a
chore: remove log (@fehmer) (#6601)
oops
2025-05-27 16:32:22 +02:00
Christian Fehmer
47de0c8a40
refactor: cleanup schema and types for CustomText (@fehmer) (#6605) 2025-05-27 16:30:49 +02:00
Christian Fehmer
1cada77ea8
fix: sanitize result filters before storing in LS (@fehmer) (#6583) 2025-05-26 16:06:17 +02:00
Christian Fehmer
19930a9079
docs: update PR template (@fehmer) (#6600) 2025-05-26 16:05:09 +02:00
Omar Abdelrahman Abbas
07c581f5b3
feat(profile): add Open Graph meta tags for social sharing (@TryOmar) (#6598)
Add Open Graph meta tags to user profile pages to improve how they
appear when shared on social media platforms. This includes title,
description and URL meta tags.

Closes #6597

### Description

This PR adds Open Graph Protocol (OGP) meta tags to user profile pages
to fix the issue with LinkedIn and other social media platforms
incorrectly redirecting profile links to the homepage. The
implementation:

- Adds dynamic Open Graph meta tags for title, description and URL
- Updates tags whenever a profile page is loaded
- Uses the user's name in the title tag for better personalization

### Checks

- [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.
- [x] Make sure to include your GitHub username prefixed with @ inside
parentheses at the end of the PR title.

<!-- label(optional scope): pull request title (@your_github_username)
-->

Closes #6597

<!-- pro tip: you can mention an issue, PR, or discussion on GitHub by
referencing its hash number e.g:
[#1234](https://github.com/monkeytypegame/monkeytype/pull/1234) -->

<!-- pro tip: you can press . (dot or period) in the code tab of any
GitHub repo to get access to GitHub's VS Code web editor Enjoy! :) -->
2025-05-26 16:04:43 +02:00
siilyg
1826948886
feat(layout): add Tarmak layouts (@siily-g) (#6574)
### Description

The tarmak layout(s) is a set of transition layouts for qwerty user
switching to colemak, it changes only about 3-4 keys for every stage.

[More about tarmak](https://dreymar.colemak.org/tarmak-intro.html)

### 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/contracts/src/schemas/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/contracts/src/schemas/themes.ts`
  - [ ] Add theme to `frontend/src/ts/constants/themes.ts`
  - [ ] Add theme css file to `frontend/static/themes` 
- [x] Adding a layout?
- [x] Make sure to follow the [layouts
documentation](https://github.com/monkeytypegame/monkeytype/blob/master/docs/LAYOUTS.md)
  - [x] Add layout to `packages/contracts/src/schemas/layouts.ts`
  - [x] Add layout json file to `frontend/static/layouts` 
  
- [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.
2025-05-26 16:03:25 +02:00
Christian Fehmer
4fe11aceee
fix(theme): dark note and reduced-motion not replacing letters with circles (@fehmer) (#6589) 2025-05-26 16:02:15 +02:00
Christian Fehmer
a9fb72de7c
perf(test): optimize test-timer checkIfTimeIsUp (@fehmer) (#6588)
During e.g. time 60 tests the CustomText.getLimitValue was called each
second which is not needed.

Refactor the checkIfTimeIsUp to only use the correct limit, either
Config.time if mode is time or CustomText.getLimitValue if mode is
custom and limited by time.
2025-05-26 16:01:44 +02:00
Pavel Ivashkov
ea144996f3
fix(language): update Ukrainian Latin to national standard (@paiv) (#6584)
### Description

In short, this PR is based on Ukraine's national standard [DSTU
9112:2021 (A)](https://en.wikipedia.org/wiki/DSTU_9112:2021), and
replaces non-standard transliteration originally submitted.

- Updates #3855

### Context

Unfortunately, this topic has been a bit toxic in Ukraine, I am sorry to
bring this on the developers of this popular tool. I am trying to stay
neutral [¹](https://paiv.github.io/blog/2024/11/26/ukrainian-latin.html
"The state of Ukrainian Latin"), with Ukraine's ultimate benefits in
mind.

At the moment, there is no definite Ukrainian Latin script. The state
standard (KMU 55) is a lossy transliteration, not useable for general
writing, only applied to personal names and places.

Practitioners of Latin script for the Ukrainian language is still only a
marginal group, without a unifying movement. Until 2021 basically
everyone had their own transliteration method, derived from two dozen
historical schemes.

In 2021 comes Ukraine's national standard DSTU 9112:2021, and
objectively is good enough for general writing among alternatives. It
does not prescribe transition from Cyrillic. Its future is in
integration with European languages, gradually replacing legacy KMU 55.

Thus my argument for the practitioners of Ukrainian Latin script is to
adopt DSTU standard, given its perspective and unifying power, and phase
out non-standard schemes, of which #3855 is only one.

I hope @tymof1j as the original contributor could critically review
these notes, with the two year perspective.

The script used for conversion from Cyrillic:
https://gist.github.com/paiv/df2f38ed86a103471a49cfa8064d0d2e

----
To reiterate, Ukrainian Latin script is not established, and people are
coming here to not only train keyboard but also to get used to the
concept of Ukrainian Latin. Hosting one of dozens unofficial
alternatives of Ukrainian Latin without giving wider context is not
appropriate. People should start with Ukraine's national standard, then
learn of alternatives, if interested.

The problem of the national standard is that it is young, and has little
adoption and tooling. Those will come in time. I have posted examples of
possible keyboard setups here: https://paiv.github.io/latynka-keyboard/

I used system A of the national standard, with diacritics. An
alternative would be to use system B, which only needs basic Latin. It
is more verbose, but is more accessible to type. I believe system A is
preferable for general text.

If this is too much for this project, I would rather remove Ukrainian
Latin than host one non-standard variant, until it is established in
Ukraine. But it is nice to keep this platform to teach the concept of
Ukrainian Latin script.
2025-05-26 15:57:13 +02:00
Seif Soliman
16eda17eb6
fix(language): incorrect and non-standard words in kazakh_1K wordlist (@byseif21) (#6570)
### Description

update & review kazakh_1K language wordlist based on feedback from
[#6569](https://github.com/monkeytypegame/monkeytype/discussions/6569)
about several issues in the list
2025-05-26 15:45:32 +02:00
Nginearing
e28aa97285
feat(language): add viossa (@nginearing) (#6571)
### Description

This adds Viosssa as a language to Monkeytype. 
Viossa is a constructed language and has even been added to Minecraft
Java Edition, and has also been assigned an ISO-639-3 Code by the
ConLang Code Registry (https://www.kreativekorp.com/clcr/)

### Checks

- [X] Adding a language
  - [X] Added language to `packages/contracts/src/schemas/languages.ts`
- [X] Added language to exactly one group in
`frontend/src/ts/constants/languages.ts`
  - [X] Added language json file to `frontend/static/languages` 
  
- [X] Checked if there are any open issues are related to this PR.
- [X] PR title follows Conventional Commits standard.
- [X] Included GitHub username prefixed with @ inside parentheses at the
end of the PR title.
2025-05-26 15:44:57 +02:00
Miodec
8f6e961b2d chore: remove anniversary elements 2025-05-22 14:05:25 +02:00
Miodec
fc2d85a9e5 chore: disable rule 2025-05-17 13:32:26 +02:00
Miodec
53bf826f08 chore: ls with schema debug logs 2025-05-17 13:30:41 +02:00
Jack
ea90e0a99e
refactor: dont allow nullable numbers (@miodec) (#6564)
Enables strict boolean expressions rule for nullable numbers
2025-05-16 16:04:19 +02:00
Miodec
cde852cf2a chore: merch banner, anniversary 2025-05-16 13:41:08 +02:00
Christian Fehmer
d3fa7c9be2
fix(commandline): cannot use mouse to select first element (@fehmer) (#6563) 2025-05-15 13:32:42 +02:00
Miodec
485eb222dd impr(account graph): round accuracy to nearest multiple of 5 instead of 10 for those accuracy freaks 2025-05-15 00:27:12 +02:00
Christian Fehmer
bfb06a22ed
impr(config): handle invalid config values (@fehmer) (#6555) 2025-05-13 16:43:45 +02:00
Seif Soliman
b34c179114
fix: smooth transition for theme palette icon in chaos_theory theme (@byseif21) (#6560)
### Description

fix the transition animation for the theme palette icon in the
chaos_theory theme.

hovering over the current theme button would trigger a smooth 180° flip
of the palette icon. However, when quickly moving the cursor away, the
icon would abruptly snap back to its original position instead of
transitioning smoothly.
### Before: 


https://github.com/user-attachments/assets/55b6683a-c83b-4f93-806b-bf289bf30c5f

-------------


### Now:



https://github.com/user-attachments/assets/59d08d45-ba2d-4921-9cc4-ee84455a0571
2025-05-13 16:42:55 +02:00
Jack
90b3d7362c
chore: update privacy policy to mention sentry (@miodec) (#6558)
Also refactors cookie modal and cokie local storage a little bit.

closes #6557
2025-05-13 16:41:48 +02:00
Christian Fehmer
98f1273398
impr(commandline): improve performance (@fehmer) (#6559)
!nuf
2025-05-13 16:41:16 +02:00