when pasting an Empty String ("") on a selected text on macOS with NSPasteboard, the selected text gets removed. that doesn't happen tho on Pages, Numbers and Keynote, old and new versions. the API is inconsistent and creates issues.
- download the source
- build the project
- give Accessibility Permissions to PagesNumbersKeynoteBugWhenPastingEmptyPasteboard
- click on the 'paste "" on selected text' button
- you then have 3 seconds to go select some text on an app
- after 3 seconds NSPasteboard will paste "" on the selected text
- you can see that the selected text is removed on any app (Safari, Xcode, third party apps) but it is not removed on Pages, Numbers and Keynote