feat(client) Support connecting/disconnecting from status bar for macOS
Adds connect/disconnect item to the menu for macOS. It will connect to last connected server if one was previously connected to.
If theres no server, it opens the app.
I wanted to mark this as a draft - I guess I cant for some reason but I need to add error handling cause right now it doesn't tell the user anything if they denied permissions to VPN.
(PLEASE test it before approving - I don't have a developer account for VPN Extensions)
Fixes: https://github.com/Jigsaw-Code/outline-apps/issues/2509 https://github.com/Jigsaw-Code/outline-apps/issues/2510 Closes: https://github.com/Jigsaw-Code/outline-apps/pull/2518
Request my review once you add error handling, @Kief5555!
For the life of me, I can't seem to passthrough the error from the menubar over to the client. Right now, on error, it will only open the app, when I get more time Il debug more
@daniellacosse, should be ready. I just ran out of app ids trying to fix the window not showing up if I closed it (not minimized) but I think it should be good?
Please make sure to test it.
I think we should at least be doing this via an
invokeFunctioncordova call.I'm out next week, so I won't be able to review again until the week after, fyi.
Sorry for the delay, I'm out from home for a bit so won't be able to work on it. By the way, do you know when dark mode will be released? Really hoping for it 😁
I think we should at least be doing this via an
invokeFunctioncordova call. I'm out next week, so I won't be able to review again until the week after, fyi.Sorry for the delay, I'm out from home for a bit so won't be able to work on it. By the way, do you know when dark mode will be released? Really hoping for it 😁
@jyyi1 should know!
Oh no here we go again... title issues
I think we should at least be doing this via an
invokeFunctioncordova call. I'm out next week, so I won't be able to review again until the week after, fyi.Sorry for the delay, I'm out from home for a bit so won't be able to work on it. By the way, do you know when dark mode will be released? Really hoping for it 😁
#2538
@daniellacosse, with the Cordova call, I'm having to write another function for it. Is it possible to leave the connect function in app.ts? This also ensures that I can bring the window up and present any errors (if they occur).
@daniellacosse, with the Cordova call, I'm having to write another function for it. Is it possible to leave the connect function in
app.ts? This also ensures that I can bring the window up and present any errors (if they occur).
Why don't you start with that and we'll see how it looks 😅
Right, sorry, I think I over complicated this. Will just undo everything and start from scratch doing direct Cordova calls instead.
Did not mean to close, was resetting the repo.
@daniellacosse @fortuna, are one of you able to fork the changes and test it please? I lack a developer account to be able to properly test this.
No, I need a developer account to be able to test the connection.
EDIT: Got a developer account from my friend but..
ProxyConnectionFailure: Failed to connect to server Outline Server. Cause: ERR_INTERNAL_ERROR: unexpected nil disconnect error
EDIT2: To fix the error above, you need to set the signing and capabilities of the Release to your own bundle ID too. Pretty hidden because it still ends up signing if you dont change it. Perhaps I can create a PR to mention this in the docs?
New error now Cause: InvalidServiceConfiguration: failed to create transport Cause: ERR_INTERNAL_ERROR: shadowsocks config missing endpoint, tho I can see it connecting because the UI Changes so I assume this works? @fortuna, What do you think? Are you guys able to pull and test on your end?
@fortuna were you able to get a chance to test it? 😄
https://github.com/user-attachments/assets/79e5efbc-14d1-4ede-9923-da45acb2deaa
@fortuna @daniellacosse got it working, please review when you get the chance
On the last part you can see the onedrive/Google Drive icon flashing indicating vpn connection
@Kief5555 No worries, we'll conduct a thorough QA test on our end. Please allow us one week for this.
Interesting, since the build is targeted towards iOS 15.5 which does support Task. Do you want me to update it to a dispatch group for async?
Interesting, since the build is targeted towards iOS 15.5 which does support
Task. Do you want me to update it to a dispatch group for async?
Task should not be a problem, we also used it, for example: https://github.com/Jigsaw-Code/outline-apps/blob/d957cb728aa166d21f46e9ddd49f8896ca7203a3/client/src/cordova/plugin/apple/src/OutlinePlugin.swift#L93
Hmm.. running npm run action client/src/cordova/build macos on my Mac builds successfully but not on GitHub?
@daniellacosse @fortuna Feel free to review this PR when you have a moment. Thanks.
@Kief5555 thanks for the contribution!
@jyyi1, sorry to bother you. I just wanted to kindly check in on whether there’s a release timeline for this feature and for dark mode. I’m heading out of the country soon and would really appreciate having them available if possible. The macOS menu bar integration in particular would be super helpful for me. Thanks so much!
@jyyi1, sorry to bother you. I just wanted to kindly check in on whether there’s a release timeline for this feature and for dark mode. I’m heading out of the country soon and would really appreciate having them available if possible. The macOS menu bar integration in particular would be super helpful for me. Thanks so much!
We're aiming to release them this week or early next week. However, we've found some critical issues, like the app crashing on most Android devices (fixed today, hopefully), so we can't guarantee the release date. We need to have a thorough QA process before the release.
@jyyi1, sorry to bother you. I just wanted to kindly check in on whether there’s a release timeline for this feature and for dark mode. I’m heading out of the country soon and would really appreciate having them available if possible. The macOS menu bar integration in particular would be super helpful for me. Thanks so much!
We're aiming to release them this week or early next week. However, we've found some critical issues, like the app crashing on most Android devices (fixed today, hopefully), so we can't guarantee the release date. We need to have a thorough QA process before the release.
I see. If you need any PR's for my pr related issues, please ping me and I will see if I can do anything!
Thanks for this! It landed a few hours ago. 🥳 Two questions:
- Was it explored to list multiple connections? Like, so that we can choose where to connect to right from the menu bar as it was before.
- Was there a reason why you didn't get rid of the
Connected/Disconnectedentry? Since we now have the connection there, it is redudantly indicated that we are connected. One time byConnectedand one time bydisconnect.
Thanks for this! It landed a few hours ago. 🥳 Two questions:
- Was it explored to list multiple connections? Like, so that we can choose where to connect to right from the menu bar as it was before.
- Was there a reason why you didn't get rid of the
Connected/Disconnectedentry? Since we now have the connection there, it is redudantly indicated that we are connected. One time byConnectedand one time bydisconnect.![]()
- I (or someone else) could implement this in a PR later. I did have the idea to do that but I thought it would be much simpler to make it connect to the last connected server.
- You're right. I will make a PR to remove this.