SpacingBat3 / WebCord

A Discord and SpaceBar :electron:-based client implemented without Discord API.
MIT License
1.88k stars 94 forks source link

Enable ⌘A shortcut to select text on macOS (fix issue #319) #415

Closed mmorella-dev closed 1 year ago

mmorella-dev commented 1 year ago

Howdy, just figured I'd re-open this PR (rebased copy of #373) in case you're doing more minor patches on the v4 branch. I want to use WebCord as my primary Discord client, but I can't without this bug being fixed.

SpacingBat3 commented 1 year ago

I've actually looked at #319 and I believe lack of select all in Edit menu is done on purpose, it's not just the macOS missing the select all but all platforms does. I think I did this as I was aware of it selecting the whole page (not just the selected input box content) and I rarely use that functionality in any of the applications (a lot of people actually don't by looking how many requests this – and I'm personally used to clicking on the text three times in the row), so I had no intentions to bringing it back.

At this rate, it's more like a feature request, not a bug 😛️… And I'm not sure whenever I want to accept feature requests in v4. Especially when large piece of the code is going to be trashed or moved to separate projects (I'm not even sure if code won't be restructured again in next to split WebCord to separate Node.js modules).

I'll leave this open for a while and rethink about it.

mmorella-dev commented 1 year ago

Regardless of whether you consider it a niche use-case or don't personally require it, the shortcut is one I use frequently enough that its absence is surprising and frustrating; I don't like switching to my mouse while editing text, and not everyone uses a mouse.

Insofar as Ctrl+A is a feature that exists in all official versions of the Discord client (and every text field in every websites and applications on my system), breaking that feature in this client is a bug or a regression by any reasonable definition.

I'm not sure why Electron gives app-developers the option to break parts of the web platform (let alone have them broken out of the box), but assuming you want Webcord to have basic feature parity with Discord's web client, you absolutely shouldn't do that.

SpacingBat3 commented 1 year ago

I won't merge this, as it only fixes this issue for macOS where it is desirable to provide this keybind for other platforms as well EDIT: NVM, it actually does – but still implements it unlocalized and that still is the reason why I prefer to implement this on my own. I'll probably do these changes on my own, it's not really that hard and costs no time so I dunno why not just get rid of stuff like this from WebCord – even if I don't see it as a future client I'll be developing. Also @morellam-dev TBH the only group that really had issues with the way WebCord is implemented are macOS users, and that was mostly because I've been never developing this app to be functional for it. And I found there might be no way for me to legally test how my software would work for macOS at all without buying Apple hardware (unlike to most OSes; even Microsoft provides Windows VM images for developers), so I kinda expect for this platform to be a bit problematic in the future as well. However, I'll try my best to make WebCord behave as most native apps and most likely make some different choices when developing my app from scratch – but as someone who never used macs, I might not be able to guarantee the same quality of support as for Windows or Linux users.

SpacingBat3 commented 1 year ago

Also, a fix should take place before next release and I plan to update WebCord quite soon, probably after I deal with updating some of its dependencies to claim newer Node.js support and (in case of ReForged) implement some new features (WebCord is not the only repo that affects the client's final code and features).