Trim common task indentation in Quick Add Magic #2072

Closed
opened 2023-09-01 10:20:23 +00:00 by xeruf · 3 comments

Description

When copying a few items from somewhere else (like a bullet list from zulip) it happens that all tasks have a common indentation.
Example:

  this is an item
  this is another

In that case quick add magic throws an error and does not add them.
Solution: first trim the indent common to all lines

Also, when the first line is blank and the second one indented (also common case when pasting from Zulip or the like), it adds the task but only displays it on reload, this lead to double tasks in my list as I saw that only later.


  this line has a blank one above it

Previous issue: vikunja/frontend#2771

Vikunja Frontend Version

try

Vikunja API Version

try

Browser and version

No response

Can you reproduce the bug on the Vikunja demo site?

Yes

Screenshots

No response

### Description When copying a few items from somewhere else (like a bullet list from zulip) it happens that all tasks have a common indentation. Example: ``` this is an item this is another ``` In that case quick add magic throws an error and does not add them. Solution: first trim the indent common to all lines Also, when the first line is blank and the second one indented (also common case when pasting from Zulip or the like), it adds the task but only displays it on reload, this lead to double tasks in my list as I saw that only later. ``` this line has a blank one above it ``` Previous issue: https://kolaente.dev/vikunja/frontend/issues/2771 ### Vikunja Frontend Version try ### Vikunja API Version try ### Browser and version _No response_ ### Can you reproduce the bug on the Vikunja demo site? Yes ### Screenshots _No response_
xeruf added the
kind/bug
label 2023-09-01 10:20:23 +00:00
Owner

Implemented in 270e32290a. Please check with the next unstable build.

Implemented in https://kolaente.dev/vikunja/frontend/commit/270e32290a28f7c94ac9624f00052d888b72a259. Please check with the next unstable build.
Author

Thanks! The second issue is not solved though:

Also, when the first line is blank and the second one indented (also common case when pasting from Zulip or the like), it adds the task but only displays it on reload, this lead to double tasks in my list as I saw that only later.

Thanks! The second issue is not solved though: > Also, when the first line is blank and the second one indented (also common case when pasting from Zulip or the like), it adds the task but only displays it on reload, this lead to double tasks in my list as I saw that only later.
xeruf reopened this issue 2023-09-18 09:12:44 +00:00
Owner

Fixed in 8507808058 - please check with the next unstable build.

Fixed in https://kolaente.dev/vikunja/frontend/commit/8507808058262997b44eea124e21e20da8dacf62 - please check with the next unstable build.
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: vikunja/vikunja#2072
No description provided.