RumovZ
f2f5eb8b6f
Add const for special fields and doc
2021-05-28 11:58:46 +02:00
RumovZ
b1dbebb1a6
Allow empty field name in templates
2021-05-28 11:37:05 +02:00
RumovZ
613320aca3
Adjusts tests to pass new template checks
2021-05-28 10:08:55 +02:00
RumovZ
044e57075e
Add checks for parsed templates
...
Combine existing check for unparsable templates with a check for unknown
field names and a check for front sides without any field replacement.
Updating the notetype's fields now mutates the parsed templates, so the
checks can run on the final templates.
2021-05-28 10:07:31 +02:00
RumovZ
d55f41669c
Use implicit failure handling and self as parent
2021-05-27 16:51:03 +02:00
RumovZ
25b6d4e31c
Escape braces in fluent string
2021-05-27 16:46:33 +02:00
RumovZ
3bb9967574
Apply suggestions from code review
...
Tweak wording of template check errors.
Co-authored-by: Damien Elmes <dae@users.noreply.github.com>
2021-05-27 13:40:33 +02:00
RumovZ
9ea349c38b
Use HashMap in identical template check
2021-05-27 12:45:17 +02:00
RumovZ
1cdf1ed96d
Check for clozes when saving notetype
...
Error if:
- Cloze notetype lacks a cloze field on either template side.
- Non-cloze notetype has a cloze field on any template.
2021-05-27 12:01:05 +02:00
RumovZ
d4a163f893
Update tests to avoid duplicate front templates
2021-05-25 21:58:12 +02:00
RumovZ
87e5266f16
Check for identical templates before saving
2021-05-25 21:57:49 +02:00
RumovZ
1b1cb420ca
Add details to TemplateSaveError
2021-05-25 21:01:03 +02:00
RumovZ
6f5100c60e
Handle failure in CardLayout/accept()
2021-05-25 20:58:43 +02:00
Damien Elmes
22b05be570
expose the ability to get/set aux notetype/template keys
...
template keys are not currently adjusted when card templates are
repositioned.
2021-05-25 22:13:53 +10:00
Damien Elmes
691a5c5c44
pass css and latex svg flag back from rendering op
...
This could potentially help us avoid having to refetch the notetype
during study in the future, though updates to Note initialization and
the LaTeX handling would be required first.
2021-05-25 18:41:43 +10:00
Damien Elmes
12b4080dd3
support passing in a native notetype object to render_uncommitted_card()
2021-05-25 16:58:06 +10:00
Damien Elmes
4b011c40ff
Merge pull request #1190 from kleinerpirat/main
...
Make legacy buttons look and feel like Svelte buttons
2021-05-25 14:20:47 +10:00
Damien Elmes
5a2a12fed0
Merge pull request #1193 from hgiesel/button-tweaks2
...
Tweak button styling for more consistency
2021-05-25 14:15:10 +10:00
Damien Elmes
01bfb5bf5d
fix a panic when browser encounters a filtered card outside filtered deck
...
the -99999 due date overflows the i32, yielding to a stuck interface
when running in a debug build
2021-05-25 13:44:42 +10:00
Henrik Giesel
1647538d63
Fix background on DropdownItem + make transitions on buttons quicker
2021-05-24 19:53:30 +02:00
Matthias M
3d50972489
Restrict inversion to images
2021-05-24 19:46:51 +02:00
Matthias M
3ecc7add82
Adjust active:hover behaviour
...
so it behaves like Svelte buttons, when clicking and dragging the mouse away from the button.
2021-05-24 13:11:50 +02:00
Matthias M
ee1fbf2a8f
Use !important instead of :not() selector
...
!important cannot be used with the radius mixin, so I had to state them explicitly.
2021-05-24 11:21:42 +02:00
Damien Elmes
c29c883e7c
mention new limit bound by reviews in tooltip
2021-05-24 19:04:00 +10:00
Matthias M
afd6e47799
Merge branch 'ankitects:main' into main
2021-05-24 10:59:02 +02:00
Matthias M
af75129974
Revert changes, add exceptions
...
to keep the PR changes as contained as possible without the use of !important.
2021-05-24 10:37:43 +02:00
Damien Elmes
822a360b40
round floats before comparing against default values
...
tabbing through the Advanced section was marking things like
'easy bonus' as modified
2021-05-24 18:26:01 +10:00
Damien Elmes
267e287c30
hard-code code color, as the tooltip background is always dark
2021-05-24 18:25:19 +10:00
Damien Elmes
5f8e895f3e
move v3 options into separate section; more description/section tweaks
2021-05-24 18:25:17 +10:00
Damien Elmes
9fed62c6a4
prevent models.setCurrent() clearing the undo queue
2021-05-24 14:54:31 +10:00
Damien Elmes
4a0758b34f
always start in first sidebar mode
...
I didn't notice anyone objecting; let's see how this is received.
https://forums.ankiweb.net/t/anki-2-1-45-alpha/10061/35
2021-05-24 14:51:21 +10:00
Damien Elmes
1f7118a8e3
config updates by the frontend now skip undo by default
2021-05-24 14:50:46 +10:00
Damien Elmes
e687ac66f3
suppress some tests around the daily rollover
2021-05-24 14:18:07 +10:00
Damien Elmes
8a796ee3c3
Merge pull request #1188 from RumovZ/switch-color-2
...
Change switch color depending on state
2021-05-24 11:42:54 +10:00
Damien Elmes
f35b471dca
make switch more legible in dark mode
2021-05-24 11:31:56 +10:00
Damien Elmes
120659fc22
Merge pull request #1183 from hgiesel/keykey
...
Switch to event.key for keyboard sequences
2021-05-24 10:53:24 +10:00
Damien Elmes
380317d701
Merge pull request #1186 from RumovZ/ctx-actions
...
Update context action states after card op
2021-05-24 10:49:23 +10:00
Damien Elmes
b57f0077f8
Merge pull request #1189 from RumovZ/fix-change-model
...
Fix browser.onChangeModel()
2021-05-24 10:49:03 +10:00
Damien Elmes
2d2e91e8f7
Merge pull request #1191 from abdnh/addmodel-fix
...
Fix wrong stock note type being used
2021-05-24 10:43:30 +10:00
Damien Elmes
ced97c1f84
fix new ease not being applied to card on lapse
...
+ zero remaining steps when graduating (they shouldn't have been doing
any harm, but this is neater)
+ add some more tests that cover these cases
2021-05-24 10:04:56 +10:00
Matthias M
066eb57283
Remove background-color transition from .button
...
but keep color, border-color and box-shadow transition as it is.
2021-05-23 19:41:45 +02:00
Matthias M
a2980e04b0
Remove CSS variable button-bg again
...
The variable is not as useful as I thought, since night mode uses a gradient anyway (and day mode is simply white).
2021-05-23 19:39:57 +02:00
Matthias M
84670cc1c2
Exclude dropdown items from night mode style
...
Makes dropdown menu look cleaner.
:not() selector did not work because the color selector button would be affected for some reason.
2021-05-23 15:58:22 +02:00
Matthias M
6cefa0f1bf
Remove transition from .linkb to fix blinking
2021-05-23 15:55:22 +02:00
abdo
9cbbdc1270
Fix wrong stock note type being used
...
https://forums.ankiweb.net/t/anki-2-1-45-alpha/10061/49
2021-05-23 07:56:59 +03:00
Matthias M
439b188b9d
Add myself to contributors
2021-05-23 01:52:29 +02:00
Matthias M
98788ca52e
Merge branch 'ankitects:main' into main
2021-05-23 01:45:42 +02:00
Matthias M
0063dcb3c8
Add CSS variable --button-bg
...
might be useful for add-on developers.
2021-05-23 01:18:00 +02:00
Matthias M
c612c41023
Make legacy buttons look like Svelte buttons
...
with extra night mode handling.
2021-05-23 00:50:02 +02:00
Matthias M
95cfd7e0b5
Invert legacy button content in night mode
...
for better visibility.
2021-05-22 22:40:21 +02:00