-
-
Couldn't load subscription status.
- Fork 61
ui: Move Report Issue to sidebar (bottom) #424
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
Changes from all commits
b649d7a
263cff8
8d20277
9b20a41
ad621d9
a07d099
4982df8
d9da7fd
8ad3b64
69010a8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -523,3 +523,5 @@ | |
| scrollbar-width: none; | ||
| } | ||
| } | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -220,10 +220,6 @@ Add any other context about the problem here.`; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <HelpCircle /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {t('user.menu.help')} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </DropdownMenuItem> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <DropdownMenuItem onClick={handleReportIssue}> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <AlertCircle /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {t('user.menu.reportIssue')} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </DropdownMenuItem> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <DropdownMenuSeparator /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <DropdownMenuItem onClick={handleLogout}> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <LogOut /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
@@ -232,6 +228,20 @@ Add any other context about the problem here.`; | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </DropdownMenuContent> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </DropdownMenu> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </SidebarMenuItem> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {/* Bottom-aligned actions */} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <SidebarMenuItem className="mt-auto" onClick={handleSponsor}> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <Heart className="text-red-500" /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {t('user.menu.sponsor')} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </SidebarMenuItem> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <SidebarMenuItem onClick={handleHelp}> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <HelpCircle /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {t('user.menu.help')} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </SidebarMenuItem> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <SidebarMenuItem onClick={handleReportIssue}> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <AlertCircle /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {t('user.menu.reportIssue')} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </SidebarMenuItem> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </SidebarMenu> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+233
to
245
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. A11y: use button components for interactive list items. Clickable SidebarMenuButton.
Apply: - <SidebarMenuItem className="mt-auto" onClick={handleSponsor}>
- <Heart className="text-red-500" />
- {t('user.menu.sponsor')}
- </SidebarMenuItem>
- <SidebarMenuItem onClick={handleHelp}>
- <HelpCircle />
- {t('user.menu.help')}
- </SidebarMenuItem>
- <SidebarMenuItem onClick={handleReportIssue}>
- <AlertCircle />
- {t('user.menu.reportIssue')}
- </SidebarMenuItem>
+ <SidebarMenuItem className="mt-auto">
+ <SidebarMenuButton onClick={handleSponsor}>
+ <Heart className="text-red-500" />
+ {t('user.menu.sponsor')}
+ </SidebarMenuButton>
+ </SidebarMenuItem>
+ <SidebarMenuItem>
+ <SidebarMenuButton onClick={handleHelp}>
+ <HelpCircle />
+ {t('user.menu.help')}
+ </SidebarMenuButton>
+ </SidebarMenuItem>
+ <SidebarMenuItem>
+ <SidebarMenuButton onClick={handleReportIssue}>
+ <AlertCircle />
+ {t('user.menu.reportIssue')}
+ </SidebarMenuButton>
+ </SidebarMenuItem>📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
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.
Add guard + fallback to avoid proxy loop and empty upstream; handle reload error
If
config.AppConfig.SSH.Hostis empty or equals the app domain, the Caddy proxy loop can reappear or config will be invalid. Also,client.Reload()errors are ignored.Apply this diff:
port, err := strconv.Atoi(containerResult.AvailablePort) if err != nil { taskCtx.LogAndUpdateStatus("Failed to convert port to int: "+err.Error(), shared_types.Failed) return err } - upstreamHost := config.AppConfig.SSH.Host + upstreamHost := config.AppConfig.SSH.Host + if upstreamHost == "" || upstreamHost == TaskPayload.Application.Domain { + taskCtx.AddLog("Upstream host unset or equals domain; defaulting to 127.0.0.1") + upstreamHost = "127.0.0.1" + } - err = client.AddDomainWithAutoTLS(TaskPayload.Application.Domain, upstreamHost, port, caddygo.DomainOptions{}) + err = client.AddDomainWithAutoTLS(TaskPayload.Application.Domain, upstreamHost, port, caddygo.DomainOptions{}) if err != nil { fmt.Println("Failed to add domain: ", err) taskCtx.LogAndUpdateStatus("Failed to add domain: "+err.Error(), shared_types.Failed) return err } - client.Reload() + if err := client.Reload(); err != nil { + taskCtx.LogAndUpdateStatus("Failed to reload Caddy: "+err.Error(), shared_types.Failed) + return err + } return nil📝 Committable suggestion
🤖 Prompt for AI Agents