-
Notifications
You must be signed in to change notification settings - Fork 108
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
3145 path selector error handling #3150
Conversation
apps/dashboard/app/javascript/path_selector/path_selector_data_table.js
Outdated
Show resolved
Hide resolved
apps/dashboard/app/views/batch_connect/session_contexts/_path_selector.html.erb
Outdated
Show resolved
Hide resolved
$(`#${this.tableId}_wrapper`).show(); | ||
this.resetTable(); | ||
if (err.message.match("Permission denied")) { | ||
$('#forbidden-warning').show(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should also focus this element at this point. If you've scrolled down past it, you can't really see it. I had to set the tabindex=0
to get it to work.
Also note that focus()
is deprecated so we'd want .trigger("focus")
(in jQuery).
@@ -43,6 +43,11 @@ | |||
<div> | |||
<ol id="<%= breadcrumb_id %>" class="breadcrumb breadcrumb-no-delimiter"> | |||
</ol> | |||
|
|||
<div class="alert alert-warning" role="alert" id="forbidden-warning"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is going to throw off the use of hide
and show
APIs because they set the styles, but I feel like this should default to class=d-none
because sometimes it shows up on initial load (at least for a second) before the javascript runs to hide it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not clear how Ubuntu tests started passing they must have updated something this morning.
But let's move while we can I suppose!
Fixes #3145
Screen.Recording.2023-10-31.at.9.54.31.AM.mov