Anki Forums

Anki 2.1.45 Beta

Due is heavily associated with review/learning cards (e.g. is:due or prop:due cannot find new cards). I know it’s sometimes used referring to new cards (e.g. in the browser), but how can a card be due without a due date :thinking:. My vote goes out for Ascending position / Descending position, mirroring ascending interval / descending interval.

2 Likes

Hello.
In Anki 2.1.45 (6ffa7440), I have a difficulty with the HTML editor. If I paste into it a table such as the following one:

<style>table {width: 100%;} td {text-align: left;}</style>
<table><tbody>
<tr>
<td>compro</td> <td>compramos</td>
</tr>
<tr>
<td>compras</td> <td>comprais</td>
</tr>
<tr>
<td>compra</td> <td>compram</td>
</tr>
</tbody></table>

the “style” element is not saved. I noticed that the table did not have the look I wanted, and when I reopened the note in the editor the element was not there. Maybe I did not understand something.
Best,
Yves

After thinking about the implementation, I’m not so sure anymore that this is a good idea, because the sidebar actions are independent of the browser table selection, but Find & Replace is not. What would be the most intuitive behaviour when the users selects Find & Replace for a sidebar item?

  1. Search for all notes/cards with the relevant tag/field and select them before opening the dialogue.
  2. Keep the current search and selection and operate on its notes.
  3. Keep the current search and selection, but operate on all notes independently of the selection.
  4. None of the above.

Made a PR:

Batch editing in particular is possible without add-ons by now, though.

This one. I would expect the action to affect all notes of the selected sidebar item, regardless of what’s selected on the browser table.

Everything else would be too complex/confusing, I think.

Is this just done through find a replace now? Or how is it done without an addon now?

Put CSS in the Styling section of the note type. What you could do is assign a classname, and style over that:

In your field:

<table class="mytable">...
</table>

In your styling

.mytable {
    width: 100%;
}
.mytable td {
    text-align: left;
}

Table editing will probably be implemented at some point.

1 Like

I like this option because it’s the most useful. But I’m concerned that this is in fact the most confusing way to do it, too.
Once the dialogue is open, the user has to remember how they’ve opened it to know which notes will be affected, because nothing will stop them from using it for something else than replacing the selected tag.
I would like to add another dropdown menu to the dialogue, which allows for setting the affected notes. The options would include “All” and “Selected”.
However, one problem would remain: The dialogue currently lists all fields of the notetypes of the passed notes. Would the list include all notetype fields when “Affected Notes” is set to “All” and change when this setting changes? Or would the list always only include the selected notes’ fields, allowing only to edit tags [edit: or all fields] when no notes have been selected?

Yes, Find & Replace is more powerful, faster and supports the new undo queue. But you need Regex, so I admit that for simple edits, the add-on is more user-friendly.

1 Like

@hengiesel Thank you for your help.
I was puzzled because in previous versions of Anki, when the HTML editor had a window of its own, the “style” element was saved and interpreted correctly.

Hmm, it feels like trying to solve this with find&replace is making things more complicated than they need to be. I find myself coming back to the “rename full tag” solution as a separate context menu item. It can pop up an editing box, there’s no confusion over what is selected or not, and we can hide it if the tag doesn’t have a ‘::’ in it. WDYT?

It looks like you can still use inline style tags (eg <table style="...">), so there’s a workaround, but putting such styling in your template would be cleaner.

Why would they have to remember? There’s still the input “Find”, which shows exactly which notes would be affected.

I see the whole idea as a useful shortcut to a prefilled Find & Replace, nothing more.

@dae That’s the only thing that would make it complicated. I wouldn’t worry about the selection at all here.


But I guess it’s true that it’s not the ideal solution for @AnKingMed’s request. How was it done in BetterTags? Editing full tag by default I think. Whatever it was, that’s what a lot of people are still used to.

I would agree, but now that I’ve looked into things, I feel like an “Affect all notes” option would be a neat feature, anyway. Like @kleinerpirat has said, Find & Replace is very powerful, but underused, and presumably more users would learn about it, if it was accessible from the sidebar.
I’ll open a PR.

If you open F&R from the browser, the “Find” input will be found on all selected notes. If opening from the sidebar would search the whole collection, the difference would currently not be reflected in the GUI.

1 Like

A ‘selected notes only’ checkbox that can be disabled sounds good to me, as it does seem to be a point of confusion.

2 Likes

A post was split to a new topic: 2.1.45 Release Candidate

But I guess it’s true that it’s not the ideal solution for @AnKingMed’s request. How was it done in BetterTags? Editing full tag by default I think. Whatever it was, that’s what a lot of people are still used to.

Editing the current tag node by default, with a separate context menu item to rename the full tag.

1 Like

@hengiese Are you happy with the state of the JS APIs, or do you think they’ll need further changes? We can always release them with a “beta/subject to change” label like has been done with the v3 scheduler if necessary - we’d just need to make a note on the add-on updating page.

I would not underestimate the amount of novice users. The solution from @glutanimate
s bettertags was super easy to use. Basically just right click on the tag, select “edit full tag” (or something like that) and a dialog came up that showed tag::subtag::subtag so you could edit wherever along the tag hierarchy

I would like new users to be able to only use drag and drop and not need to manage hierarchy by textual input at all.
But I appreciate the majority vote. :slight_smile:

2 Likes

This would be awesome. I’m not 100% sure how to do it… but it would be cool!

I have a problem with 2.1.45 beta6. When I review a “type” card, after pressing the “intro” key from the numpad, nothing happens if the focus is on the text input field. Before, it works like the “enter” key to see the answer. If I click outside the text field to change the focus, then I can use “intro” from numpad similar to “enter”.

It was comfortable to review my cards with one hand on the numeric keypad, aside “1”, “2”, “3” for again, hard, good, and so on.

Should be fixed in the next build