Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6693- Fixed replacing lists and odd spacing #6735

Closed
wants to merge 3 commits into from

Conversation

lzach83
Copy link
Contributor

@lzach83 lzach83 commented Feb 14, 2024

Link to Issue

Closes: #6693

Description of Changes

  • Fixes an issue where if you have a current list and want to change list types it would just append to the front instead of replacing the list
  • In lists this also fixes the odd spacing where when you copied the string it would apply extra \n in between

"How We Fixed It"

  • Edited createListHandler to check if there's a previous prefix and append/replace with the new one
  • Trim the ends of the strings in order to eliminate the odd spacing in the lists

Test Plan

  • Go to create a thread or comment
  • Highlight and create a list
  • then switch between all of the lists
  • Copy the contents
  • Paste somewhere and ensure the spacing is correct

Copy link
Collaborator

@jnaviask jnaviask left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Going between bullet list and numbered list inserts a space at the beginning of each line.

@lzach83
Copy link
Contributor Author

lzach83 commented Feb 14, 2024

@jnaviask Should be fixed now, thank you

@masvelio
Copy link
Contributor

I am not sure what works and what does not in this PR, but I am listing out things that definitely do not. Please explain which of those supposed to be fixed in this PR and if we have tickets/PRs for other issues.

  1. on create thread page load I have this error Uncaught TypeError: Cannot read properties of undefined (reading '___isMarkdown') at eval (react_quill_editor.tsx:112:1) - (0:01s)
  2. list buttons do not work - they do not insert list into the text field - (0:05s)
  3. when I highlight list items and select ordered list, the list has not have order but every element has number .1 - (0:14s)
  4. pasting the list copied seconds ago gives line breaks even though there was no line break before, in editor and outside - (0:38s)
Kapture.2024-02-20.at.16.12.23.mp4

@lzach83
Copy link
Contributor Author

lzach83 commented Mar 6, 2024

This will end up getting closed by #6512 leaving open until it gets merged.

@lzach83
Copy link
Contributor Author

lzach83 commented Mar 6, 2024

#6512 Merged -- this ticket is redundant

@lzach83 lzach83 closed this Mar 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Editor lists should be replaced not added to
3 participants