-
Notifications
You must be signed in to change notification settings - Fork 22
Opening a coder_app in a new browser window is awkward #297
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
Opening a coder_app in a new browser window is awkward #297
Comments
Instead of doing it in the provider, I propose adding it to User settings. cc: @coder/pms? |
Some apps really need nav buttons. IMO this is something where at least the defaults should be declared at the app level. |
Yes for choosing a full window vs a slim window. I agree but adding tab vs window could be a user option. |
As I investigated this ticket and started to work on it, here are a few things. Comments
Steps to implementConsidering that want to implement the solution described in the ticket - here are the steps :
cc @dannykopping for visibility. |
Er... maybe as a follow-up item? Let's focus first on this issue.
Is it about validation? so that admin can't really configure the window behavior for |
Agree - thanks. I'll open a second issue once this one is validated so we keep track of it.
My concern is more about adding an option to the templates - I feel like only a small percentage of our templates are browser-based - the other ones opening the native software. This option applies only to the browser-based modules. So if we add the option to the modules, it means it will be ignored for all the non browser-based modules. Is it fine ? |
For no browser-based modules, we use |
This PR is the coder/coder part of [the open_in parameter issue](coder/terraform-provider-coder#297) aiming to add a new optional parameter to choose how to open modules. This PR is heavily linked [to this PR](coder/terraform-provider-coder#321). ℹ️ For now, some integrations tests can not be pushed as it requires a release on the terraform-provider repo.
Second step to resolve [open_in issue](coder/terraform-provider-coder#297) This PR improves the way the open_in parameter is forwarded across the code, changing the last `string` to const everywhere. Also make sure it is available and forwarded up to the `CreateLink` component.
Just reopening it for now until we merge the FE changes into main. Does that sound okay, @defelmnq? |
@BrunoQuaresma All good yeah , no problem ! ✅ |
@stirby Unfortunately, it seems we won’t be able to implement the window option as intended. Some browsers don’t support opening a new window with navigation options—or at least, I haven’t found a reliable way to achieve it. A user on Stack Overflow mentioned a related issue with Chrome, and when I tested it on Safari, I encountered the same limitation: it doesn’t allow opening new windows with navigation features. As a user, I don’t think there’s much difference between opening the app in a new tab versus a new window. We could consider simplifying this by removing the window option altogether or reworking it to have just two choices: tab (opening a new tab) and popup (opening a smaller, focused window). Wdyt? |
I see, thanks for investigating this. My mistake for not jumping on this sooner; in the future, let's validate that the FE supports our expected behavior before changing the DB to support it @defelmnq. The two options (tab, focused window) are sufficient. The new window with navigation is always achievable by pulling out the tab, just some users are unaware that the new tab keybind is possible. Allowing admins to force it with the So we should remove the |
Perhaps it isn't a huge problem as long as we document the behavior that some browsers do not support it? As a developer I would not be surprised |
@mtojek’s suggestion works for me too, but I’d only proceed with it if the window option adds real value. Many users don’t typically read the docs before using the product, so I’d prefer to minimize potential issues stemming from third-party services/software whenever possible. That said, I’d request help from @defelmnq for the BE changes 💪. |
Another idea @BrunoQuaresma: in browser - could we silently switch the behavior to PS. I'd like us to be convinced that discussed all possible options. |
After some research, it seems there’s no API available to determine how
Definitely 👍. I’m approaching this from more of a product perspective—if the option doesn’t provide clear value, we should consider removing it to reduce maintenance overhead and potential user confusion. |
After investigating a bit more (unfortunately late..) indeed :
I would agree with Bruno, as there's two options here :
cc @stirby @mtojek for the decision - I would personally vote for the removal of While I can work on removing the option on the backend (which should be pretty fast) - Bruno can work on the FE implementation anyway, as the option is already available. And sorry for the lack of validation here at first. |
Agree. Let's not elongate this topic anymore, it is a minor feature. The frontend part should be straightforward. |
Problem statement
Currently,
coder_app
s open a slimmed down browser without navigation buttons or tabs. While the slim window maximizes display space for the app and makes it feel like a local process, apps like the filebrowser suffer from not having forward/back arrows.You can open the apps in a new tab then pull them into a new window; but, not all users are aware of this shortcut. We're also missing the Shift+Click keybind to open a fresh browser window.
Solution proposal
We add a new property to
coder_app
likeopen_in
with options to specify the default method of opening the app. We should also achieve parody with chrome keybindings. This attribute would set the default on-click behavior:tab
window
slim-window
(default)For example, the following would open the app in a full new window on regular click or shift+click, and a new tab on ctrl+click.
The text was updated successfully, but these errors were encountered: