Commit graph

11571 commits

Author SHA1 Message Date
Damien Elmes
bd3d97c370 Further tweaks to easy days
The previous commit added word-wrap, but it was not working after I'd
removed some other tweaks I'd made in testing, that I thought were not
required. I ended up switching to standard table columns and a fixed
layout, so that both the column and row headers will wrap properly.
2025-02-11 17:04:58 +07:00
Damien Elmes
9469583a7d Quick hack to improve minimum deck options width
Partial fix for #3796
2025-02-11 16:11:43 +07:00
Jarrett Ye
99a0e49b73 Add margin to the bottom of forgetting curve (#3805) 2025-02-11 15:46:36 +07:00
GithubAnon0000
66e2a332ba Update reviewer.py to prevent custom scheduler js from commenting out py code (#3795)
* Update reviewer.py to prevent custom scheduler js from commenting out py code

* Do not use custom code, but move {js} instead
2025-02-09 16:06:49 +03:00
llama
d62fd820e4 only change notetype/deck when reopening if no changes to discard (#3798) 2025-02-09 15:58:21 +03:00
Luc Mcgrady
bb6fa647a6 Remove forgetting curve radio buttons when only one radio button (#3804) 2025-02-09 15:53:05 +03:00
Damien Elmes
a0f8c152fc Bump version 2025-02-06 22:59:27 +07:00
Damien Elmes
ce5be0a9e7 Update translations 2025-02-06 22:59:19 +07:00
llama
4d3b2d0352 clear io image field when resetting in add mode (#3794) 2025-02-06 22:58:49 +07:00
Damien Elmes
10a7e84f13 Prompt user to apply Windows updates when SSL connection fails
See #3793
2025-02-06 22:57:15 +07:00
Damien Elmes
cffaa1856a Give editcurrent its own menubar too
Closes #3785
2025-02-06 18:57:59 +07:00
Danika-Dakika
47debcc96e Update Deck Options strings to clarify Timers (#3792)
* Update CONTRIBUTORS

added myself

* Update about.py

added myself

* Update scheduling.ftl

timers-related string changes

* Update deck-config.ftl

timers-related string changes

* Update help-page.ts

timers-related string changes
2025-02-06 15:17:30 +07:00
llama
5cb10b10f4 add cut handler in TagInput (#3791) 2025-02-06 14:26:44 +07:00
dependabot[bot]
4c37bd615b Bump vitest from 2.1.3 to 2.1.9 (#3790)
Bumps [vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest) from 2.1.3 to 2.1.9.
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v2.1.9/packages/vitest)

---
updated-dependencies:
- dependency-name: vitest
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-06 14:24:51 +07:00
Jarrett Ye
7c5a1b7e28 Fix/disable FSRS short-term scheduler if w[17] or w[18] is zero (#3788)
* Fix/disable FSRS short-term scheduler if w[17] or w[18] is zero

* fix bracket

* rename variable
2025-02-06 14:24:40 +07:00
llama
2647d864c0 Cap preview cols to prevent stall when csv is parsed with the wrong delimiter (#3786)
* cap csv import preview table at 1000 columns

* add fluent message

* show warning when preview table columns have been truncated

* simplify fluent message ($count will almost always be a big num)

* _tr -> tr
2025-02-06 14:23:43 +07:00
Luc Mcgrady
44b6c2970f Added: SpinnerBox percentage symbol. (#3777)
* Added: Padded percentage symbol

* Added: Floating percentage

* ./check

* half finished comment

* Removed: redundant toStringValue function

* Removed: Accidental import

* Improved pointer-events:none

* Improve percentage alignment

* Improve leftmost percentage alignment

* Fix: Percentage sticks to left

* ./check

* Fix: IOS css

* ./check
2025-02-06 14:21:26 +07:00
Luc Mcgrady
dff4d4e770 Delete y-axis titles for graphs (#3789)
* Remove simulator y axis labels

* Remove forgetting curve y-axis title

* ./check

* Mark the card-stats string as deprecated as well (dae)
2025-02-06 14:17:39 +07:00
Damien Elmes
5647055a3f Latest openssl CVE 2025-02-03 15:17:07 +07:00
Jarrett Ye
a1e9db1ce5 Update to FSRS-rs v2.0.3 (fix simulator) (#3784) 2025-02-02 23:35:34 +07:00
llama
46f45ac6b7 Fix discard changes randomly being a noop on certain linux systems (#3781)
* fix discard changes randomly being a noop on certain linux systems

* use QApplication.setActiveWindow instead

* revert current impl

* wait for the next event loop iter before calling activeWindow
2025-02-02 23:31:36 +07:00
llama
a68e034edc add image context menu actions for io mask editor (#3779) 2025-01-31 00:06:29 +11:00
llama
755ca896a4 fix error when right-clicking empty space in update addons dialog (#3780) 2025-01-30 23:42:27 +11:00
Expertium
b1bd75e36e Added "preset" to "Optimize all" and "Optimize current" (#3778)
I think this one really calls for a poll. Dae, I highly suggest you to ask multiple users whether "Optimize current" and "Optimize all" are clear enough or need "preset". I'm pretty sure most people will find it confusing without "preset".
2025-01-30 23:41:01 +11:00
llama
6003062580 Add drag/drop support when adding IO images (#3776)
* allow adding images via drag/drop when adding io

* support editing io notes as well

Co-authored-by: Abdo <abdo@abdnh.net>

---------

Co-authored-by: Abdo <abdo@abdnh.net>
2025-01-27 18:58:58 +03:00
llama
b52e53425c fix copying images with filenames containing reserved chars (#3775) 2025-01-27 16:57:31 +03:00
Damien Elmes
162b607e27 Hack in a fix for wheel generation 2025-01-27 01:20:58 +11:00
Damien Elmes
7172a7b4d3 Auto-expand bundle progress in Buildkite on Linux 2025-01-26 19:37:34 +11:00
Damien Elmes
d37a9339c4 Bundling got broken in the revert to Qt 6.6 2025-01-26 19:32:01 +11:00
Damien Elmes
0859249fb8 Bump Rust to 1.84
+ fix new warnings/lints
+ update pyo3 to fix some other warnings
2025-01-26 18:51:21 +11:00
Damien Elmes
5adeaa334d Update translations 2025-01-26 18:20:40 +11:00
Damien Elmes
5a278f671a Reviews graph: orange -> blue
Closes #3764
2025-01-26 17:45:14 +11:00
Damien Elmes
1ccb4757c1 Fix drag&drop on some Linux systems
Thanks to Ab_Bc:
https://forums.ankiweb.net/t/image-occlusion-not-working-jan-2025/54523/17

Closes #3767
2025-01-26 17:31:54 +11:00
Damien Elmes
e8f5a20aa0 Fall back to SM2 relative order when memory state missing (#3771)
Closes #3770
2025-01-26 17:26:46 +11:00
Damien Elmes
e1745c24a3 Use a simple menubar for addcards on macOS
This makes initial-open and reopen behaviour consistent.

Closes #3659
2025-01-26 17:05:09 +11:00
Damien Elmes
d895aa729e Yarn 4 (#3772)
* Update to yarn 4, and pin the version

* Use yarn to invoke prettier, as yarn 4 is not setting +x

* Fix a few peer dependency warnings
2025-01-26 14:40:17 +11:00
Mike Hardy
d632198aa7 build: specify the canvas transitive node dependency build failure workaround in future-compatible way (#3752)
* fix: specify canvas npm optional dep ignore workaround more cleanly

this should allow it to work with yarn classic and yarn modern

* chore: add self to CONTRIBUTORS
2025-01-26 11:57:30 +11:00
Jarrett Ye
8f8db1b350 Fix/re-optimize FSRS if short-term param is weird (#3742)
* Fix/re-optimize FSRS if short-term param is weird

* Reset progress when another run is required (dae)

* only count the same-day steps

* Fix flicker when optimizing again (dae)
2025-01-26 10:42:17 +11:00
Damien Elmes
fa93b6e1c9 Move Optimize All action into main deck options page
Closes #3696

I have no strong feelings about the message/button wordings or
layout, so if people have better suggestions, they are welcome.
2025-01-25 22:57:05 +11:00
Damien Elmes
4c975eb9b5 Use prettier's cache
Approximately halves runtime on my system
2025-01-25 22:52:25 +11:00
Damien Elmes
a19b283947 Use Qt 6.8 on ARM Linux; add tools/run-qt6.8
Prior to this change, ./run fails out of the box on ARM systems, as Qt
wasn't available on PyPI until the 6.8 release.

Also added a script in tools/ for testing Qt6.8 issues on other platforms.
2025-01-25 21:59:31 +11:00
Damien Elmes
5b13d02f77 Revert "Qt 6.8.1"
This reverts commit 04228de666.

Anki 25.01 Beta 1 revealed a bunch of regressions with the latest
Qt, and zero reports of improvements from it, so we'll be better off
holding off on it for now, and perhaps reporting the deadkeys issue
to Qt once we've got a proper reproduction process.
2025-01-25 21:41:33 +11:00
Luc Mcgrady
9d5d3a2ba9 Fix: Simulator Ignores New Cards Already Introduced (#3760)
* Subtract introduced:1 count from learn count of first day of simulator.

* Fix: Cards filtered

* Tidy up

* Fix: Cards filtered (2)

* ./check

* Removed unnecessary filter

* Fix: Doesn't work for real new cards

* ./check

* Fix: .is_none()

* Limit to 1 day

* Removed "days_to_simulate" argument from convert
2025-01-25 21:16:25 +11:00
user1823
99b6a47bb9 More accurate sorting by R (#3747)
* Match calc of relative overdueness in SM2 and FSRS

* Fix calculation of FSRS relative overdueness

* Improve readability by avoiding double negative

* Move comment line
2025-01-25 21:15:49 +11:00
llama
a178e10256 Fix numeric deck and notetype names being treated as ids when importing csv (#3748)
* fallback to treating deck and notetype ids as names

* add test for metadata
2025-01-25 20:13:30 +11:00
Omar Kohl
d944befba8 Ignore SYNC_PORT and SYNC_BASE in syncserver Dockerfile (#3716)
Hardcode them to:

    SYNC_PORT=8080
    SYNC_BASE=/anki_data

If these env variables are passed into the container with different values,
they are ignored.

The reasons is if the user modifies SYNC_BASE they risk data loss since
anki-sync-server will no longer write data into the volume. If they change
SYNC_PORT they need to also change it when mapping this internal port to the
external port of the container, which could be confusing plus it has no benefit
to allow this since it's always possible to change the external port even if
the internal port is fixed to 8080 (e.g. `-p 1234:8080`).

In both cases there is no benefit to making these values configurable and there
are risks associated.

Unfortunately there is no easy way of implementing this for the
Dockerfile.distroless so it's up to the user not to modify these values.
2025-01-25 19:28:55 +11:00
Damien Elmes
4f0cc19646 Update translations 2025-01-25 19:25:24 +11:00
Ross Brown
cdd442b07c Add translation strings for True Retention table (#3745)
* Add translation strings for True Retention table

* Hard-code strings to make pylint happy
2025-01-25 19:18:43 +11:00
GithubAnon0000
8ff9691723 FIX lang selection resetting to en_US for some langs (#3744)
* FIX lang selection resetting to en_US for some langs

Fixes https://forums.ankiweb.net/t/anki-25-01-beta/54490/17?u=anon_0000.

# Issue
Set a hand full of certain languages in the preferences screen and see that the translations have been applied after reboot. The language selection in preferences wrongly shows en_US though, not the current active language. If you wanted to switch to `en_US` in this case, then you'd have to first switch to a working language (like de_DE) and then switch to en_US.

# Solution
`anki/qt/aqt/preferences.py` has the functions `setup_language()` and `current_lang_index()`. I noticed that it defaults to en_US, if the language is not in `compatMap` and it couldn’t return the index of the current language. No idea if this code is faulty but I headed over to `anki/pylib/anki/lang.py` afterwards.

Here, in `compatMap`, I added e.g. `"la": "la_LA"`. I knew the code since I could get it with `print("––– lang is ", lang)` in `preferences.py` (`current_lang_index()` retrieves `la` for latin).

After adding those code changes from my PR, the problem for those selected languages had gone away.

No idea if that's best practices though or if something else should be fixed instead.

* UPDATE CONTRIBUTORS adding myself to the list
2025-01-25 19:14:50 +11:00
llama
6a2210efb8 fix changes to tags not being reflected when editing in io mode (#3768) 2025-01-25 10:36:21 +03:00