Commit Graph

464 Commits

Author SHA1 Message Date
3a4814d3a8 Server cleanup 2021-07-18 10:34:13 -07:00
6a68046fee Add helpers 2021-07-18 10:31:47 -07:00
NSBum
4e41429165
Fixed deck config id actions (#273)
The follow deck configuration actions were updated to conform to Anki’s current deck configuration access. Specifically, `decks.conf` is no longer available.

setDeckConfigId no longer check for existence of configuration id, because the access to the list of config id’s appears to be only through decks; and the config may theoretically be orphaned.
2021-07-14 18:22:10 -07:00
a34c1de0b4 Minor tweaks to readme 2021-07-13 17:58:27 -07:00
NSBum
8404bd782d
Added guiCheckDatabase action and fix #202 in saveDeckConfig (#271)
* Added guiCheckDatabase action

This action initiates a check database action in Anki but doesn’t wait for the action to complete before returning.

* Fixed #202 no dconf attribute in saveDeckConfig

Anki manages access to deck configuration differently now. This adapts saveDeckConfig to new style of access.
2021-07-13 17:55:22 -07:00
toasted-nutbread
2150940c7e
More create note duplicate options (#269)
* Simplify access to note['options']

* Add checkAllModels option

* Update documentation
2021-07-12 19:46:22 -07:00
Jason Won
591ac06aa3
allow guiAddCards to add media (#266)
* add media to editing note

* update readme
2021-06-20 20:35:09 -07:00
9c6a62d20b Remove old action docs 2021-06-08 22:58:05 -07:00
689cbf2d86 Update README 2021-06-08 20:50:53 -07:00
c9f0cc61c3 Update README 2021-06-08 20:42:38 -07:00
grepmew
a6406107e4
Resolves #223 by removing unnecessary image markup (#260) 2021-06-03 14:36:04 -07:00
abdo
f8ff7c0c38
storeMediaFile: Add option to keep file with the same name (#257) 2021-05-22 12:21:12 -07:00
DegrangeM
9fec86f7fe
Add requestPermission API method (#255)
* Add requestPermission Api Method

* Add documentation about requestPermission method

* Update version documentation
2021-05-07 20:33:06 -07:00
Kirill Salnikov
17d8ecf60f
Update createModel method to create Cloze models (#250) 2021-05-06 19:11:03 -07:00
DegrangeM
1a08d79454
Fix documentation (#253) 2021-05-05 22:31:26 -07:00
DegrangeM
9472ac4401
Fix vulnerability (#252)
* Improve and simplify code handling CORS

* Don't execute request when origin not allowed

Fix vulnerability

* Remove webCorsOrigin legacy option

It's confusing (and potentially insecure as removing webCorsOrigin in configuration would still set it to localhost)

* Allow 127.0.0.1 and browser extension if localhost allowed
2021-05-05 22:31:11 -07:00
Konstantin Sukovatij
929716c7b1
Added "getMediaFilesNames" action (#247) 2021-04-11 21:26:03 -07:00
abdo
2081330c35
Compare field names in a case-insensitive manner (#242) 2021-03-13 16:10:58 -08:00
9a18ae0b11 Better compat with old versions of Anki 2021-03-06 21:16:19 -08:00
Quentin Harscoët
27a8678f88
added getNumCardsReviewedByDay action (#239)
* added getNumCardsReviewedByDay action

* added sample in statistics.md

* fix bad quotes and add basic test
2021-03-06 09:58:40 -08:00
Kirill Salnikov
b8a7151ed0
Fix handling of errors in several methods (#238)
* Fix error message in updateNoteFields method

* Fix error handling in cardsInfo, notesInfo methods

* Add more tests for updateNoteFields, notesInfo

* Fix error handling in several methods

Also fixed obvious bugs in replaceTags and replaceTagsInAllNotes
methods.

* Add more tests for cards methods

* Add more tests for notes methods

* Update documentation on cards methods
2021-03-04 20:06:25 -08:00
Tsung-Po Sun(Munehiro)
a4d723de3e
Add "forgetCards" and "relearnCards" (#234)
* Add "forgetCards" and "relearnCards"

* Add unit tests

Co-authored-by: Tsung-Po Sun <tsungpo.sun@smartnews.com>
2021-03-04 20:02:57 -08:00
Venkata Ramana
131a1c7cfc
Added findAndReplaceInModels (#228)
* added findAndReplaceInModels api call

* added documentation for findAndReplaceInModels

* added findAndReplaceInModels api call

* updatd findAndReplaceInModels function

* added unit test for findAndReplaceInModels in models

* updated findAndReplaceInModels

* added unit test for findAndReplaceInModels

* removed 'all_models' in findAndReplaceInModels
2021-02-26 21:17:51 -08:00
ripose-jp
aaf6b3a55b
Fixed bug where hash was calculated using the wrong variable (#235) 2021-02-26 21:16:39 -08:00
421ca35c09 Fix missing return 2021-02-22 19:25:12 -08:00
Alexander Ryzhikov
8b81267b0c
Add Access-Control-Allow-Headers * (#231) 2021-02-21 11:24:08 -08:00
David Sauerwein
7ef10e92da
Allow to add media to notes by file path or base64 encoded data (#230)
* Allow to add media to notes by file path or base64 encoded data

* Adjust Media Actions documentation

* Adjust Note Actions documentation
2021-02-20 10:04:25 -08:00
Kirill Salnikov
4d2ab991c2
Fix bug in loadProfile method (#229)
Bug: if sync is enabled for profile, then we have alot of recursive
calls to loadProfile method because main window is still active until
sync is ended. And this freezes Anki app.
2021-02-07 17:40:44 -08:00
6487abe206 Fix typo 2021-01-19 21:59:45 -08:00
a8273d0e38 Fix tests 2021-01-18 21:03:27 -08:00
322984be06 Cleanup 2021-01-18 20:18:57 -08:00
abd2fea76f Merge branch 'cleanup' 2021-01-18 12:37:03 -08:00
636af8828d Update README 2021-01-18 12:36:47 -08:00
a575388392 Update quotes 2021-01-17 22:27:20 -08:00
c0cdc8e575 Update copyrights 2021-01-17 22:15:48 -08:00
431ee362fc Initial cleanup pass 2021-01-17 22:13:27 -08:00
eyeinsky
99c031ca8e
Add links to query syntax documentation (#211) (#224) 2021-01-09 14:17:10 -08:00
Venkata Ramana
c55281d67a
added removeEmptyNotes (#221)
* clearUnusedTags and replaceTags are added

* added clearUnusedTags and replaceTags

* added clearUnusedTags and replaceTags

* removed whitespaces and indentations

* removed white spaces and indentations

* added removeEmptyNotes
2021-01-04 18:01:56 -08:00
Venkata Ramana
311cb7e192
replaceTags and clearUnusedTags are added (#219)
* clearUnusedTags and replaceTags are added

* added clearUnusedTags and replaceTags

* added clearUnusedTags and replaceTags

* removed whitespaces and indentations

* removed white spaces and indentations
2021-01-02 09:05:35 -08:00
kanjieater
5386364c8d
Server no longer hangs on client disconnects (#217)
* Server no longer hangs on client disconnects

* Changed timeout and am now catching errors explicitly

Co-authored-by: KanjiEater <kanjieat3r@gmail.com>
2020-12-28 13:57:22 -08:00
Ren Tatsumoto
9bbaf79575
Fixes 08f0d0c (#215) 2020-12-12 08:41:01 -08:00
Ling Wang
08f0d0cb7e
Add file parameter to storeMediaFile (#208) 2020-12-07 18:50:37 -08:00
grepmew
06dff21107
Add support for video and pictures when adding or updating a note. (#207)
- Sound and video share same [sound:..] tag. See 0c08ff5317/pylib/anki/sound.py (L33)
- Tested and verified picture is added and video is added when `addNote` API.
2020-12-05 21:24:50 -08:00
toasted-nutbread
b03414a8d3
Don't call note.dupeOrEmpty when mode is 'deck' (#204)
* Don't call note.dupeOrEmpty when mode is 'deck'

* Update return type to be consistent with latest note.duplicateOrEmpty

* Fix main deck ID not always being included
2020-12-05 21:23:03 -08:00
toasted-nutbread
ab1f518474
Duplicate scope options (#203)
* Add additional options to addNote's duplicateScope option

* Update documentation
2020-11-01 16:14:30 -08:00
Bryan Jenks
b19bd7902d
The button text differs from README (#192) 2020-09-05 13:31:50 -07:00
Julian Müller
ce0cc7dce3
some additional actions (#185)
* implement needed actions

* add documentation and tests for cardInfo, updateCompleteDeck, reloadCollection, cardReviews, getLatestReviewID, insertReviews

Co-authored-by: Julian Müller <julian.mueller@stud-mail.uni-wuerzburg.de>
2020-07-12 12:53:31 -07:00
Spencer Sharp
84586cb352
Created getEaseFactors and setEaseFactors for Cards, along with documentation and tests for the functions (#181)
Co-authored-by: sherpa <spencersharp1999@gmail.com>
2020-06-10 16:21:58 -07:00
CRIMX
5438b19ba1
Remove localization for field names (#178)
Remove localization for field names as it creates agnostic output.
2020-06-02 20:27:33 -07:00
745fd34b83 Update README 2020-05-24 17:50:48 -07:00