Changes between Initial Version and Version 1 of Ticket #42059, comment 2
- Timestamp:
- 10/02/2017 08:44:03 AM (7 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #42059, comment 2
initial v1 1 1 Couple more ideas: 2 2 3 1. Instead of using span(s) for the selection marker, perhaps better to use a zero-width element like <wbr data-wp-selection="start|end" />`. These will be quite easier to remove from HTML strings. We can also style them in CSS, no need for inline styles.3 1. Instead of using span(s) for the selection marker, perhaps better to use a zero-width element like `<wbr data-wp-selection="start|end" />`. These will be quite easier to remove from HTML strings. We can also style them in CSS, no need for inline styles. 4 4 5 5 2. Keeping selected text is ok, but not essential imho. It's rare to switch editors while something is selected. The important part is to keep the position of the caret and to scroll to it after switching. If there is a selection, consider collapsing it to the beginning and using only one <wbr> for a marker. For images, shortcodes, and other embeddable "blocks" we can collapse to before the beginning, even insert an empty paragraph in MCE then remove it after switching to Text. That way all previews and "dynamic blocks" will work properly no matter where they come from.